Why are light bulbs coated with phosphorus?

They aren't. Ordinary filament lamps aren't coated with anything at all. The inside of fluorescent lamps are coated with a mixture of phosphors (NOT phosphorus but very complex metal salts). Fluorescent lamps work in two major steps. The electric current causes mercury vapour to emit ultra-violet light. The UV is absorbed by the phosphors and they re-emit it as coloured light. The mix of phosphors are there to emit a variety of colours so that the overall effect is a white light.