Opiates are the most effective cough suppressants, I'm guessing that was the reasoning behind it.
Cough is a symptom, meaning there is a problem in the patient's respiratory system the doctor should be looking into. Suppressing it is the equivalent of pasting a post it with a happy face over the fuel gauge when the needle is approaching the Big-Red-E.