Why don't people know when they have halitosis?

Can't smell. It is very difficult if not impossible to smell your own bad breath. The only way to really know is if other people tell you or offer you mints or gum a lot. The taste buds and olfactory sense are very closely related. The nerves of this system become desensitized to the smell and taste of the halitosis over time. A neurologist could probably explain it better, but in a nutshell you can't smell it.
Getting used to it. Bad breath is something that develops over time, so most people who have it have kinda gotten used to it as its developed. It's a slow change, kinda like the example of throwing a frog into a lukewark pot of water and slowly heating it up. Eventually you can get the critter up to a boil without him ever jumping out because he's slowly adjusted to the temperature (even though he can't survive it).
Nose got used to it. A person's brain is more sensitive to "changes" in aroma and can "ignore" odors once he's smelled them for a while. Halitosis occurs for several reasons. Chemicals from some foods/drinks diffuse into the flesh in the mouth and throat. These chemicals (odors) keep coming out into the breath for many hours. Some foods/drinks cause odors when in the stomach. Some substances stick to the teeth.