There are many types of electric motors. In terms of basic structure, their composition is mainly composed of stator and rotor.
The stator is stationary in space, while the rotor can rotate around the shaft and is supported by bearings.
There will be a certain air gap between the stator and the rotor to ensure that the rotor can rotate freely.
The stator and the rotor are wound with coils, and a current is applied to generate a magnetic field, which becomes an electromagnet. One of the stator and the rotor can also be a permanent magnet.