He could be rubbing it on something rough because it itches. Keep an eye out for other spots on his skin - just in case it is some sort of skin infection.
Does it extend down to his vent like he might be impacted or infected and trying to relieve himself?
Poor little guy. Vet asap, and he needs a parasite check, so take fresh droppings with you.