Question about ADC in arduino

I learn to use arduino UNO with piezoelectric and from the article in
it tell the piezo can generate -12 to 20 V so we have to add 1Mohm resistor parallel sensor and connect with ADC pin of arduino. My question is why we put 1Mohm resistor parallel with the sensor can make the voltage down to -0.5V to 0.5V thank you

update I from the picture in the guide does it call voltage divider ?

Is says 'safer'.. not 'safe'.
Go for a zener-diode to shunt 5V+ and a schottky diode to prevent negative voltage.
A SERIAL resistor from sensor (low k-range) will bring current to safe limits

Piezo elements are current sources, not voltage sources, so adding a burden resistor sets sensible output

If 1Mohm gives 0.5V peak, then the device is generating 500nA peak. Not actually enough to damage an
input protection diode in fact.

update I from the picture in the guide does it call voltage divider

All voltage sources have an "effective" internal source resistance/impedance (which may not act exactly like an actual resistor)

So yes, you have something like a [u]voltage divider[/u] where the "top" resistor is hidden inside the device.

For example, when you put a load on a battery (or power supply), the voltage drops. With a light load (high resistance and little current) the voltage drop might be too small to measure, but with a heavy load (low resistance and more current) the voltage drop will be significant. ...Batteries are probably a bad example because they also discharge over time.

A voltage regulator on a power supply or battery tries to hold the voltage constant when the load varies (and when the input voltage varies). So a voltage regulator is lowering the effective source impedance of the power supply. That is, it's making it "act like" it has a low source impedance as long as you stay within the specs/normal operating parameters.

A piezo element is basically a small (1-10n) capacitor.
Without the resistor across the piezo we have a 'floating' pin (for DC).