Just ease of administration. IME 9/10 will eat the granules with no problem at all, but fewer than half will eat the pills without a bunch of gymnastics to hide or disguise them. I don't have time for that nonsense.
I was wondering this myself a few months back. I stuck with the granules though because they were enteric coated which if what I have read on the subject has been correct, is necessary to get the drug to the appropriate point in the horse's digestive system for it to be effective.
My gelding had to stay on Ranitidine for the latter part of his competitive career. my vet just called the Rx in to SmartPak & they not only ground it up for me, but added flavour. Yes, it cost a little extra, but after I spent 10 days grinding up pills & putting them in reused containers...it was worth it. He just got it with his meals at the boarding facility at the time.