Yes, a garden room can have a bathroom. As with bedrooms, building regulations will apply (to a limited extent) and planning permission may also be required. See our guide to plumbing for more details.