The madman thinks the doctor, like everybody else in the country, is a cannibal who is merely checking how fattened the madman has became, rather than checking his pulse.
When we find out that Lu Xun originally went to school to be a doctor, and that he deeply distrusted traditional medicine practiced in China because of his father's death, we can see that the madman's distrust of the doctor is more significant than first realized. We can read the passages one of two ways: either the madman represents Xun and his refusal to believe in the traditional methods of the doctor, or the madman represents the Chinese population, refusing to believe that the doctor is acting in their best interest. All we really see of the doctor in the story is the pulse-check and advice (to paraphrase) for the madman to take it easy for a little while, which is something that would probably have been suggested in any time period. So, it is up to reader to decide which way to read the passages and, by extension, the story.
As to the question of whether or not a doctor can be and cannibal (and how), the answer is quite simple. Doctors are still humans, so it is entirely possible (if improbable) for a doctor to be a cannibal. All he or she would have to do is consume some flesh, just like everybody else.