If it's made of clay and it was properly fired in a kiln, it becomes what's known as bisque and should be fine even if it's not glazed. But it'll be particularly fine if it is glazed. That is, if it has a shiny, waterproof, slick surface like glass on the outside.

Only if a clay piece hasn't yet been fired will it turn to mush if it gets in water. And no one would sell an unfired piece as a pipe to be put in someone's mouth. Besides, unfired, dried clay is very fragile.

I'm taking a pottery class right now and learning about all these things as we speak.