Potty training/ability is in stages:
1) peeing in toilet
2) pooping in toilet
3) Night-time dryness.
Peeing in toilet usually comes first. Then, pooping in toilet comes later... sometimes much later.
Night-time "dryness" can take even up until 7 year old, and this is NORMAL. Night-time dryness has to do with biology as well. Not just the child "knowing."
The thing with pooping is... if you force it, it makes it worse. AND, the child can become constipated.... because then it will be an emotional problem, not just a biological need, and they will "withhold" their poop... because of anxiety. And once the child becomes constipated... it becomes harder and harder in consistency, and then it becomes difficult to pass and it will cause pain upon pooping. So then the child will NOT want to poop, anywhere, even in a diaper.
AND if the poop becomes constipated and hard, and builds up inside the body, it can cause medical problems.
I know this because this happened to my Daughter and we had to see a Pediatric Gastroenterologist for it. THIS is what he said. It is common in toddlers who are potty training. That pooping ability on the toilet will take time. Do not make it a forced event. Or they get hang-ups, which then causes MORE of a problem for the child.
And yes, at night, MANY Kindergartener's are still in diapers as well. Its normal. Per our Pediatrician as well. A child, will NOT "master" all 3 of these stages, at the same time. It happens one at a time. Taking time between each stage.
Potty training, can take lots of time, if the child is not ready.
My daughter is 7 years old, and she did not reach full night-time dryness until 5 years old. BUT, keep in mind, that pee accidents will still occur, in any child. Even if they are potty trained. My daughter still has an occasional night-time accident... because she sleeps so deeply as well.
I just put a water-proof bed pad directly under her at night, to make clean up easier, for me. No problem.
Your son is real young, to have ALL of these things mastered. MANY MANY MANY kids at this age and older, still wear night-time diapers.
Its okay.
All the best,
Susan