Have it checked
A 6yo usually doesn't make up stuff about their body parts.
If he says it hurts, i would believe him. With this complaint, i often the penile opening has narrowed down to too small an opening & may need to be dilated. If the kid has a strong stream that is unlikely. Some also can get soap irritation if they clean the area vigorously.Rarely i've had a kid put an object in the hole & hurt it.