Cs4PbBr6 is a member of the extended halide perovskite family that is built from isolated (zero-dimensional) PbBr64- octahedra with Cs+ counter ions. The material exhibits anomalous optoelectronic properties: optical absorption and weak emission in the deep ultraviolet (310-375 nm) with efficient luminescence in the green region (∼540 nm). Several hypotheses have been proposed to explain the giant Stokes shift including: (i) phase impurities; (ii) self-trapped exciton; (iii) defect emission. We explore, using first-principles theory and self-consistent Fermi level analysis, the unusual defect chemistry and physics of Cs4PbBr6. We find a heavily compensated system where the room-temperature carrier concentrations (<109 cm-3) are more than one million times lower than the defect concentrations. We show that the low-energy Br-on-Cs antisite results in the formation of a polybromide (Br3) species that can exist in a range of charge states. We further demonstrate from excited-state calculations that tribromide moieties are photoresponsive and can contribute to the observed green luminescence. Photoactivity of polyhalide molecules is expected to be present in other halide perovskite-related compounds where they can influence light absorption and emission.