I still don't see why they didn't do this as they had weapon racks in Skyrim. Then again those were buggy as hell.
Best alternative is to drop it on the ground then use the workshop mode to place it on a shelf.
I definitely will look forward to a weapon rack mod. Nothing like walking into a room with guns lining every wall.