Hard drives are fixed with special screws through shockproof pads, the user controlling the strength of the fastening. If you’ve fastened the screw fully, the drive is fixed just like in a metal rack, so you don’t have to worry about its safety. After the drive is installed, the case is to be put back into the case and fixed with its screw.
It’s even simpler with the floppy drives cage: no screws, just a latch.
When you pull at the lever, the latch is released and the cage can be taken out from its place.