How does a volcano function?

how does a volcano function? how does a volcano function? how does a volcano function?