It is obviously a product defect, because the printer worked without any problems until the end with the last cartridge. Therefore, describe the defect of the product and send it back with a request for replacement. I would complain in advance by telephone and describe the fault. After all, these things are expensive enough that with the name "HP" you can expect flawless products.
No. According to the manufacturer's website (https://h22203.www2.hp.com/SureSupply/?AppName=CustomerCare_docs&searchTerm=HP%20Color%20LaserJet%20Pro%20MFP%20M277dw) you need HP 201A toners. You can find these under the following link:
https://www.digitec.ch/de/s1/Search?q=201A