How does boiling water extract dyes from vegetables?
These dyes (NOT pigments$^*$) are highly water soluble. As you pointed out, boiling causes cell walls to rupture, releasing the cell plasma into the water. Boiling of the plasma fluid causes pressure build up, something the cell walls aren't designed to withstand.

You can also extract them with cold water by mashing up the raw material in a food blender or grinding it in a mortar and pestle. This has the same effect of rupturing the cell walls.

An interesting fact is that many of these dyes are pH sensitive: their colour is different in acid or alkaline conditions. Notably red cabbage extract changes from wine red to greenish blue when you add some sodium bicarbonate (baking powder) to it, because 'Bicar' is a (weak) alkali. Then adding a lot of vinegar (a weak acid) will change it back to its original colour.

$^*$ pigments are inorganic substances (many are refined minerals) and mostly insoluble in water.