Quicksand is a naturally-occurring fluidized bed, in which the upward welling of the water works against gravity to suspend the individual sand particles. They’re pretty free to move around without friction, which is why you can easily fall into it. But the same forces of welling up also push *you[/] up, which is why you won’t “drown” in quicksand.
The sand acts very weird, almost “alive”, which is what the “quick” is “quicksand” means. It’s the same archaic sense of the word as in the phrase “the quick and the dead” (meaning “the living and the dead”), or in “cut to the quick” (meaning a cut that goes through the dead outer layers of skin to the inner, bleeding portion).
So the Al Jaffee joke (“Is this quicksand?” “No, it’s slow sand. What’s your hurry?”) doesn’t really apply.
As you can imagine, the conditions that allow quicksand aren’t that common – you need an upwarxd rush of water from someplace, like an artesian well, or ocean waves. Hence the appearance of quicksand near the shore.
There are plenty of other situations in which you can get caught in mud, bogs, etc. that aren’t “quicksand”, but which resembles quicksand in the way it grabs you , so people call it “quicksand”, even though it isn’t. (Just as those hallucinations seen in the desert in cartoons aren’t really “mirages”. But the incorrect name sticks.) I got my shoes caught in very liquid clay once as a kid. Trying to pull one foot out only pushed the other deeper. People get caught in thick mud and sucking bogs the same way. In these situations you don’t float, and the recommended solution for extricating yourself from quicksand doesn’t work exactly as sold.
If you rapidly shake a mixture of sand and water, even without an upwelling, it “fluidizes”, and heavy objects on top will easily sink into the mixc, then get stuck there when the vibration stops. This can happen during earthquakes. Reportedly, houses built on wet sand can get completely buried this way.
Similarly, if you build a quicksand tank like they did on Mythbusters and some joker shuts off the water pressure while you’re in there, you will get stuck, and the recommended solution won’t get you out. In fact, you might end up with a problem breathing. You need someione to turn the water back on to get you out. This may be one reason Home Quicksand Tanks never really took off.
By the way, for lots of interesting references on the weird physical properties of beach sand (why does it “dry out” when you walk on it?) see the ever-recommended-by-me Flying Circus of Physics by Jearl D. Walker.