This is a pretty weird 'problem' for me. I always only close the lid when leaving my macbook, today I did the same. After an hour or so, when I checked find my iphone, i saw my macbook as online, in my backpack at my dorm. I waited half an hour hoping that it'd show as offline, but whenever I checked it became online. I freaked out, thinking that it'd overheat and burn it mainboard inside my backpack. Apple help says that macs are findable if and only if they're turned on and connected.
Long story short, I ran to my dorm and my mac was kinda asleep, wasn't hot. Battery went down from ~30 to ~16. I tried to put my mac explicitly to sleep and check if I can see it's location from my iphone. Yes, I was able to see it as online.
Is this a problem?
TL;DR
Apple help says macbooks are online iff they're turned on and connected to the net, but my experience says they're also online when they're sleeping, draining battery.
Best Answer
Yes this is normal. Nothing to worry about.
It part of Power Nap, which was introduces in MacOSX Mountain Lion (10.8). When your Mac is asleep the following features will run as your Mac gently snoozes:
These all run regardless of whether the notbook is plugged in or not, which is impressive as regards power use. Power Nap might look like a little bullet point on the Mountain Lion spec sheet, but it really is a big deal, especially for those non power users (aka. Normals) who never bother with updates and the like. And the sleepy Find My Mac feature is just plain magic.
Source: https://support.apple.com/en-us/HT204032