Eggshells are made primarily of calcium carbonate. The acid in vinegar softens the calcium of the eggshell. Adding a little vinegar to the water when boiling eggs is an old cook’s trick that makes them easier to peel.
A link to this experiment is below in the comment box