What happens is this:
Your HVAC equipment includes 3 phase motors. When the PoCo lost a phase, the motors that were STILL RUNNING will STAY running and act as a type of Rotary Phase Converter to generate a phantom voltage on the missing phase, but without the added capacitors to boost and stabilize it. So although the utility may have completely lost the phase, you had SOME local voltage generated from the spinning motors, but not enough for the total load on line at the time. So the voltage dropped just enough to keep the contactor from holding in, but as soon as it dropped out and the load on the UPS went away, the voltage increased, so the contactor pulled back in. As soon as it did, the added load dropped the voltage again and it dropped out. This happens very fast and it "chattered", which will smoke the contacts and coil very rapidly.
The trick to preventing this is to have Phase Loss protection in your system that will detect the phase loss from the utility and disable all of the controls for everything that is 3 phase. that event put a lot of stress on those running 3 phase motors too.