If you use the search on top you can search for bedtime wetting and see answer after answer that kids that wet during the night can't help it. There is nothing they can do to stop it.
It is a biological function. The brain turns on a chemical that stops the kidneys from producing urine when the child goes to sleep. Then when they wake up the kidneys start the production and they have to go pee.
Kids are not supposed to wake up to pee during the night. They're supposed to go to sleep then sleep all night.
If you wake a sleeping child to take them to the bathroom it only makes them clench the muscles up. Then they sit there and don't go or they simply dribble a bit. As soon as they go back to sleep they pee. They can't help it.
So really, put an overnight pull up on this child and put a plastic cover on his mattress then a mattress pad so the plastic won't be so hot. He'll leak occasionally but it won't be as bad. Diapers are just not meant to wear for that many hours. If the pillow gets wet go buy a new one because the time and effort to wash it and dry it costs more than it can be replaced for.
************************************************
As for the daytime stuff, he's a kid. He's still growing and working on stuff in his body so it's normal for him to leak a tiny bit. When he goes help him to bear down and get the bladder as empty as possible. Then try to get him to go every couple of hours.
I can tell you that in all my years in child care that almost every kid I have even known has issues around the time they turn 5-6, I think it's a growth thing and not anything they want to do on purpose.