The role of volatiles in magma chamber dynamics