To tame a donkey you don’t actually need to have any supplies, but if you want to keep the donkey I suggest you use a saddle and a rope so you can properly ride it and it won’t run away afterward.
When you find a donkey, walk up to it and mount the donkey. He will likely buck you off his back. Keep mounting him over and over and eventually, a bunch of hearts will appear above his head. This is similar to the hearts that appear above wolves when you tame them. Once you have tamed the donkey you can ride around on his back, but will not have any control over where he walks.
In order to have some control over where the donkey walks, you will need to put a saddle on his back. You can find saddles in dungeon chests. Alternatively, if you do not have a saddle but want to keep the donkey you can use a rope. You can then lead the donkey to a fence and tie him to the fence so he doesn’t run away.