Volcanoes can be made in several different ways, all stem from the same idea.
At divergent boundaries, two tectonic plates are slowly moving away from each other until a gap is created between the two. Magma from under the Earth’s crust rises to the surface to fill the gaps and cools on the surface. The crust is thin here due to the constant pull of the two plates and more magma can leak through, creating a Volcano.
This is when two plates collide and the less dense plate submerges under the denser. The submerging plate starts to melt and this weakens the plate above. This weak spot allows magma to get through to the surface and thus a Volcano forms.
Inside the Earth’s mantle is magma, and sometimes a hot magma plume can rise within this, melting and weakening the Earth’s crust above on a fixed spot. Eventually, this magma can seep through, creating a Volcano above.