Power factor correction is not a requirement of the NEC nor most nations codes or regulations.
Any such equipment that is installed, should of course comply with NEC or other relevant codes.
Poor power factor results in greater currents for a given load, than would otherwise be expected.
Improving the power factor reduces such currents and may permit of smaller and therefore cheaper cables etc.
Large industrial consumers are often penalised financialy for poor factor, therefore power factor correction is a financial and engineering judjement issue, not a code requirement.
Poor power factor may be improved by fitting capacitors, either to individual items of equipment, or centrally in a switch room.
Domestic consumers in most countries are not penalised for poor factor and there is therefore no financial gain by improving it.
More detailed information may be found in any good electrical engineering textbook.