Basically in physics a magnet electrically charged posses a energy form called electromagnetic energy.
This one posses a hole and a particle when made. Obviously particle will go in the hole and this is why electricity is defined as flow of electrons. Electromagnet is a temporally charged one used in MRI's, robots, etc.