ed, that's a great idea, but the closet company still has to be involved from the start.
Since they don't "have the inclination" to help out, you can be sure they're avoiding liability. They have no pressing need to even provide a disclaimer. They want to install a cabinet and go away. And get paid. And never hear from the client again.
The rear panels of such closets are not always right up against the wall, and can be an entire inch off the wall.
The more I thought about this approach, the more questions I had.
Is that 21" dimension inside the cabinet, or outside the cabinet?
If it's inside the cabinet, there's 1-3/4" between the back of the rack (19-1/4" deep) and the wall. If it's the outside dimension, there's about 1-1/8" space behind the rack. Minus, of course, whatever space the back panel is from the wall.
I've never seen one of these racks installed with less than six inches behind the rack. How will you deal with the wiring?
You're totally right about how clumsy it is to try to install equipment in a space like this. So,,, It's also occurred to me that you can't use the entire width of the closet space if you use a rack. I'd seriously consider putting in a wood shelf plus a vertical divider, placed so that an old-style A/V component (17-1/8" width) could be put in at a later time if needed.
Your actual usable space would almost double if you did not use a rack. It's worth a think or three.
A good answer is easier with a clear question giving the make and model of everything. "The biggest problem in communication is the illusion that it has taken place." -- G. “Bernie” Shaw