What causes magnetism? Electric fields are caused by particles that have charge. Gravitational fields are caused by particles that have mass. What is the property of a particle that causes it to interact with a magnetic field?
I've read that magnetic fields are caused by charged particles that are moving in an electric field. However, since any charged particle in an electric field experiences a force on it which causes it to move, doesn't this mean that an electric field is impossible to detect without a magnetic field also being present, and vice versa? How would a magnetic field and electric field differ in this case?
I've also read that magnetism is caused by groupings of particles with the same spin state. Is this the quantum mechanical explanation, and if so then how do groupings of such particles create a magnetic field?
 A: If all the spins are aligned, then a magnetic field is created. It is the direction of the spin that causes the attraction or repulsion (As far as my understanding goes)
An electric field can be created by a stationary charge (electrostatics). It is only when this charge moves that the magnetic field is created. 
A: I will try to explain it in the simplest way that I can think of. The magnetic behavior depends on the following factors:
1)the subatomic particles present in the atom
2)atoms
3)collection of atoms
4)domains(collection of collection of atoms)
1)THE SUBATOMIC PARTICLES AND 2)ATOMS
Subatomic particles have some basic fundamental properties like mass, charge, etc. In the same way they also have a property called as intrinsic magnetic moment(which is basically the measure of their tendency to align with magnetic fields)and they could be basically thought of as some sort of tiny magnets that can align themselves to a magnetic field. We can not ask why they behave like tiny magnets because it is how the universe works just like how objects with masses attract each other. The intrinsic magnetic moment of protons is about 1000 times weaker than electrons and as a result, the nucleus of an atom does not have much effect on magnetism. The movement of electrons creates a magnetic field but the magnetic field of an atom is not due to all of the electrons of an atom. The electrons in the filled shells are found in pair and their magnetic field is aligned in such a way that it cancels each other. But the electrons are not found in pairs in approximately half-filled shells and their magnetic fields are aligned in such a way that they add up rather than cancel each other out, as a result, the magnetic field of an atom depends mostly on approximately half-filled shells(more accurately incomplete shells). Some magnetic atoms are those of the elements: Ni,Co,Fe,Cr,etc.


*COLLECTION OF ATOMS
: If a material's atoms are magnetic the entire material need not have to be magnetic. When a collection of atoms is taken into consideration then the following may happen:(the probability of either of them happening depends on which takes the least energy for that particular material's atoms )
A)The atoms may align their magnetic fields with each other in such a way that they add up together to create a magnetic field. When this happen the material is called ferromagnetic material like Fe(below its curie temperature).

B)The atoms may align their magnetic fields in an alternating way in such a way that they cancel out each other's magnetic field. When this happens the material is called nonferromagnetic or antiferromagnetic  like Cr. (even though chromium atoms are individually very magnetic but due to this they(collection of atoms) are very  nonferromagnetic )
C)The atoms may arrange themselves in a messy way in such that some of them are aligned while others are not and some even cancel each other. So basically they are very feebly magnetic and are called paramagnetic materials.


*DOMAINS(COLLECTION OF COLLECTION OF ATOMS):

The image shows a magnetised and unmagnetized piece of ferromagnetic material.
The individual blocks are the collection of atoms while the entire material consists of billions of collection of atoms each with their magnetic field pointing in different directions mostly. But when the material is kept in a sufficiently strong magnetic field then it causes the individual domains to align together into a big domain (the magnetized piece) and their individual magnetic fields add up. This is what causes magnetism.
A: In order to answer your question one must examine the smallest known magnet thus the Quantum Magnet which is the electron.
The nature of the intrinsic magnetic dipole moment of the electron has two interpretations. The Amperian thus the  Ampère's law in Maxwell equations for electromagnetism where a spinning charge creates a current loop and therefore gives rise to a magnetic moment or the Gilbertian (William Gilbert) interpretation where the electron has two magnetic monopole charges (N and S) joined in a dipole formation. Both models can give the same correct predictions. As of which of the two is the physical correct and existing no one knows experimentally today.
