Why are boogers sticky?
No doubt your child is starting a brilliant scientific career with this question!
"Boogers" are made of mucus. Mucus is made by mucus membranes. Your body has mucus membranes in all sorts of places: The stomach, intestines, nose, lungs, eyes, mouth, and the urinary tract all contain mucus membranes that secrete mucus.
Mucus contains mostly water and mucin (during a sinus or lung infection, it also contains dead white blood cells that have been working on the infection -- see How Your Immune System Works for details). It is the mucin that makes it sticky.
Mucin is a branched polysaccharide. If you have read How Food Works, then you know about saccharides -- they are sugar chains. Starch, for example, is a polysaccharide. As you've probably noticed, if you mix corn starch or flour with water, you get a sticky substance. Mucin is doing the same thing. Mucus is essentially a thin paste made of mucin and water.
Show your four-year-old how corn starch and water is sticky (especially as it dries out) and he will be looking at synthetic boogers! Then ask them if they would like to eat it. If they say no, then tell them not to eat their own.