If my school aged kid wanted to wear diapers to school I would let them.
A diaper would be a good idea so the kid doesn't have to take potty breaks and doesn't have to hold it in to use the toilet.
The kid could just go pee in the diaper and change the diaper later.