This is the way of creating new words we call 'translition from one part of speech to another' or just 'translition' (переход). Nouns can be created such way.
For instance:
Спальная - sleeping room (from спальная комната - комната, где спят)
Шампанское - champagne (from шампанское вино)
Рабочий - worker (exactly this one was formed somewhere in XIX-early XX century from рабочий человек