Try another way, or another day, and the donkey just might surprise you. Occasionally, a donkey will test you, and for your safety you must be the boss, a kind friendly one, but still the boss. You have three seconds from the time of the infraction to let said donkey know in no uncertain terms that that is a no-no. If you delay in reacting - then forget about the punishment, the donkey won't know why his is being chastised. Over-doing punishment is a sin for longears, so think before you act.
Donkeys can quickly become sullen and resentful from unnecessary abuse.
Donkeys on the whole are very gentle, peaceful creatures. Most importantly, enjoy your donkey. Don't get caught up in just wanting to get those certain lessons done as soon as possible, but cherish the time that you spend together, and the lesson becomes a means of furthering your communication and enriching your friendship. And of course, listen to your donkey. He can be your best teacher.