It used to be a staple of junior high physics class to build some sort of motor with paperclips or wire. A coil creates a magnetic field that makes the rotor move. In the process of moving, brushes ...
Hard drives work by spinning platters full of magnetized data while a read/write head very quickly harvests or changes bits as needed. Older (or perhaps cheaper) drives spin at 5400 RPM, better drives ...