Where to install a carbon monoxide detector when the boiler is in a closet?
I'll start by saying that I'm a big fan of following instructions. However, there are exceptions to rules sometimes.

Let's assume for the sake of argument that you don't spend an inordinate amount of time in the closet with the boiler and the door closed. So risk of CO poisoning in there is pretty slim.

Let's also assume that you spend time in the living space. If you place the CO detector in that living space, it should warn you of danger without being overloaded by proximity to the appliance.

So, I'd put it in the hall by the closet.