Head to the shop, select your pet, and browse the items available for it. Purchases are made with whatever currency your account holds, and anything you buy is applied to the pet you had selected at the time.
So the one thing to get right is the selection step — buying while a different pet is active is the usual reason people end up with an accessory on the wrong animal.