Why do I need a pull down resistor in the button example?

(if it's not connected to the ground, the pin will read random noise from the environment?)

that's it !
if there were no link between pin and 0V (GND here), the input would be floating when button is not pressed, because of the very high input impedance. The resistor gives this link needed to make sure the input is at 0V in this case. A wire would not allow the pin to be HIGH when button pressed, as it would make a short between 5V and 0V