The apocrine glands open into the hair follicles. Hair follicles are the tube-like structure that holds hair on the skin. You can find apocrine glands in the groin and armpits. These glands produce sweat that you can smell when you come in contact with bacteria on your skin.
The apocrine glands don't start working until puberty, which is why young children don't smell body odor. The Swiss study also suggests that the use of deodorants may be more important for women, as an independent panel of sniffers found that the smell of sulfur onions was more disturbing than the masculine cheese fragrance.