AOG: " Closet: A private or small room especially one used for private devotions or study
The private apartment of a monarch
A room etc for urination and defecation, a lavatory
A private repository of valuables, curiosities etc
A cupboard, a recess for storage (Now dialect & North American ) " [Shorter Oxford English Dictionary]
Take your pick ! Some of the above might fit. However, unless you, or they, are speaking some English dialect ,the speakers are using an Americanism. You are to be commended for defending the British way, but " Come out of the cupboard" has something of a comical ring about it . Nearest translation should , perhaps ,be 'Come out of the wardrobe" but that sounds distinctly of the French farce tradition and heterosexual !