One of the original stories of a person getting turned into a donkey is
The Golden Ass by Apuleius, and this plot point also features in the famous story of Pinocchio. Donkeys often symbolize stubbornness or ignorance, and so Rabadash’s transformation into a donkey is a fitting punishment for his refusal to reform his ways.