Unfortunately, it's hard to say for sure and my feeling is that it really varies from school to school. If you stay at the same school for your PhD, I bet a lot of the courses will count. If you switch schools it will probably be a lot more variable - it doesn't seem like any of the schools that I was accepted to would waive me out of a lot of core nutrition classes (despite my having a BS and a masters), but because my masters is in public health, they were much more flexible about waiving requirements like Biostats and Epi. The number of courses schools are willing to waive is pretty variable too. From poking around on admissions websites, some have a hard cap on the number of credits that they'll accept from previous coursework.
Generally, the way that it works is that you may have an informal discussion about it at some point during the admissions process (I always asked - some places told me it was no problem, some said it would depend on the syllabus, etc) and once you were formally enrolled, you'd submit an official waiver petition that typically requires the syllabus of the course you took and the evidence of your grade in the course and then your department would rule from there. I'd imagine it's likely that your advisor would have to sign off on it too.