When you home your machine, if the Z axis moves down towards the bed, it means you have a limit switch triggered somewhere on your machine and you have used the "Override Limits" button to reset and move the machine. If you try to Home the machine with the "Override Limits" button active, the Z-Axis will move straight down until it eventually crashes into the bed.
The "Override Limits" button is only to allow you to reset and jog the machine off any limit switch that may currently be engaged. Once the limit switch is disengaged, the "Override Limits" button will no longer flash red and you can home the machine. Another method to clear the switch is to engage your physical E-Stop button, which will cut power to the motors and allow you to turn the lead screws by hand to physically disengage the limit switch. For example, if your Z-Axis is on a switch and is all the way up, you can turn the screw about 1-2 turns until it is no longer activating the switch.
You can tell if a limit switch is currently active in your diagnostics screen in UCCNC. Below is an example of a machine with a limit switch currently active (green).
Note that the X, Y and Z limit switches are all on the same circuit, so when one is active all will show in UCCNC as active. This does NOT mean all three are active.