Traditional sewage treatment technology cannot remove heavy metals, which needs to be improved urgently. Lysinibacillus with the function of bio-mineralization was screened and loaded on granular sludge to form a phosphate-mineralized bacterial consortium, which demonstrated the ability of self-regulating pH and automatic solid-liquid separation. Heavy metals could be fixed on the bacterial consortium to produce stable and harmless phosphate minerals. The highest removal efficiency of Pb(Ⅱ), Cd(Ⅱ), and Ni(Ⅱ) were 97.9%, 70%, and 40%, respectively. Organic matter and other metal ions in actual polluted water had little effect on the Pb(Ⅱ) removal efficiency. Mechanism analysis was conducted through 3D-EEM, XRD, SEM-EDS, XPS, FTIR, and high-throughput sequencing analyses. The bacterial consortium was a multi-species coexistence system, but Lysinibacillus played a major role in removing Pb(Ⅱ). C-O and O-H bonds of tyrosine and phosphorous organics were broken by enzyme catalysis and the metal-oxygen bond (Pb-O) was formed. Mineral crystals in the reactor accumulated, transforming from the initial phase non-crystalline structure to the metaphase Pb3(PO4)2 and eventually to the Pb5(PO4)3OH. This research obtained a promising technique for immobilizing Pb(Ⅱ) or other hazardous metals continuously and efficiently.