From the few details you have given, it is not possible to arrive at a diagnosis. However, whether the problem is a complication caused by puberty or not, it exists. There are known methods for toilet training, which you should find out about.
Many autistic children have a problem with the sense of smell. Possibly he does not experience the same disgust as we do. However, for a full diagnosis and treatment schedule, you must go to an expert institution.