E&M, electricity and magnetism are very intertwined. A magnet is nothing more than an element with a bunch of the atomic level electric fields lined up, instead of randomly laid down.
A constant electric field will attract electrically charged particles, but not magnetic particles. A changing electric field will create a magnetic field and attract magnetic particles. So basically, run a current in a wire and you will get both electric and magnetic fields. Wrap the (insulated) wire around an iron or steel rod in the same rotation and you'll create a combined stronger magnetic field.
Here is a very low level run at E&M
https://www.thoughtco.com/introduction-electricity-and-magnetism-4172372#:~:text=Electricity%20and%20magnetism%20ar e%20two%20related%20phenomena%20produced,induces%2 0electric%20charge%20movement%2C%20producing%20an% 20electric%20current.
I am a Mechanical and Electrical Power Engineer, but not an "Electrical Engineer". I know enough to be dangerous...