If I was doing that, there would be a certain amount of time that it would take me to pull the fader down to reach three dB, it's not just instant. W quickly it responds to that is all in the controls. If I had my finger on the fader, and you told me, "okay, every time the snare drum hits, bring it down three dB and then put it back." that's effectively what you're doing to a compressor, and how you tell it to do that is all in the controls and ho. At its very simplest, a compressor is just an automated volume control. There are so many different ways you can treat, you can process a file using a compressor to get a completely different emotional result at the end. They're probably the single most important tool for creating a sense of power and a sense of glue and a sense of urgency. Where if you have some knowledge of they work, they're an incredible tool. The tendency is for people to misuse them or use them far too much, or not realize that perhaps the compressor they're using is really not contributing anything to what they're doing.
To me, compression is one of the least understood aspects of mixing, especially for people just getting into it.