There are nothing known as sunpots. But there are sunspot.It was discovered by galileo.He noticed that there are few areas on the sun where there is less helium which causes less fire that is why sunspots are dark in colour.
Sun spots are actually parts of the Sun that flare up and out away from the Sun due to the Sun's great energy. These flares are huge, but soon cool some as they move farther from the Sun. When photographed with a camera, say, that is adjusted to the Sun's awesome brightness, the sunspot, being cooler, thus less bright, show up as black dots or black patches.
the sun's magnetic field is responsible for sun spots and "space weather". the sun is a ball of plasma, a gas comprised of ions and electrons rather than neutral atoms. because ions and electrons have charge, they attach themselves to magnetic field lines. the sun rotates, so the material in the sun is in motion, however the equator and poles rotate at different speeds. this causes the magnetic field (which is locked into the material) to twist and contort, occasionally snapping and rebounding manifesting as solar flares, sunspots, and various other phenomena.