As someone who has had to design spaces specifically for acoustical concerns, carpeting/rugs can have a negligible effect on acoustics in general-use settings like homes and office spaces. Carpet can deaden foot traffic noise and high frequencies but as far as helping to tune a room for mid-range and low-end frequencies for audio enjoyment, it's not much help. Of course, the carpet/rug salesman will tell you their product will solve all your acoustical issues but caveat emptor.
Floor treatments can add warmth and visual softness to a space if you want to make it more liveable and aesthetically pleasing. Ceiling and wall treatments are the most effective surfaces to look at.
In my future listening den, I plan to take room measurements after I have a semblance of furnishings, final finishes, and the built-in bookshelves are filled up because I don't intend to build a listening box with nothing in it but a chair.
Depending on how tech-savvy you are, you could try free software out there to build a 3D simulation of your room and then listen to it virtually to see how it may sound with different treatments or hire professional services to do that for you.
If I were designing a custom listening space for a client and they have top-end hi-fi gear and want a truly neutral room, then I would recommend hiring an acoustician to assist in designing the right room treatments and dialing in the correct dimensions for a room.