Some codes require specific types of detectors. They provide an early warning which is critical because the longer the delay, the deadlier the consequences. Read the manufacturers instructions that come with the detector for advice on the best place to install it. Install one detector on each level of the house, and one outside the sleeping areas. Follow the manufacturers' instructions for proper maintenance.
Smoke detectors can save lives, but only if properly installed and maintained.
Never disconnect a detector. Relocate the detector rather than disconnecting it, if it is subject to nuisance alarms. Replace batteries promptly. Follow the manufacturer's instruction about cleaning your detector. Excessive dust, grease, or other material in the detector may cause it operate abnormally.