There are different types of motors, but perhaps they are the so-called “direct current motors” that allow to see in a simpler way how to obtain movement thanks to the magnetic field created by a current.
The graph schematically shows the main parts of a DC motor.
The element in the center is the part of the motor that generates the movement. It is called an armature or rotor, and consists of an electromagnet that can rotate freely around an axis. Said rotor is surrounded by a permanent magnet, whose magnetic field remains fixed.
The electromagnet receives current through the contact between the brushes and the switch. The brushes remain fixed, while the switch can rotate freely between them following the movement of the rotor for more full inside motor you can check this out https://minhmotor.com/danh-muc/dong-co-dien-motor/.
When the current passes along the electromagnet, its poles are attracted and repelled by the poles of the fixed magnet, so that the rotor will move until the north pole of the electromagnet is facing the south pole of the permanent magnet. But as soon as the rotor poles are “looking” at the magnet poles, there is a change in the direction of the current passing through the rotor.
This change is because the switch, when rotating, modifies the contacts with the brushes and exchanges the way in which the electromagnet receives the current from the battery.
When the sign of the poles of the electromagnet is modified, the poles of the rotor will be repelled by the poles of the fixed magnet, because in this new situation will be faced poles of equal sign, with which the rotor is forced to continue turning.
Again, when the poles of the electromagnet are aligned with the opposing poles of the fixed magnet, the brush-to-switch contact will modify the current direction, whereby the rotor will be forced to continue to rotate.
Answering our initial question, what do they have in common a refrigerator, a washing machine and a fan ?, the answer is that the three appliances have an electric motor that allows their operation.