We don't have a proper closet so we're always looking for things like this: It's a retractable garment rod from Colonial Bronze. The rod is concealed inside a wall or door, with only the flush end of the rod exposed.
When you want to hang an item, the rod extends out 9". Made of solid brass, this high quality hardware is available in 39 finishes, so you're sure to find one that works for you. Available in a modern design as pictured above or a more traditional design with a decorative rosette on the end of the rod.
We can see this being used as a retractable towel rod in small bathrooms, too.