It's a versatile word that means "and", "but", "by the way".
나 뭐 좀 물어볼 게 있어. I have something to ask.
나 뭐 좀 물어볼 게 있는데. I have something to ask. (implies "Do you mind my asking?")
뭐해? What are you doing?
뭐하는데? What are you doing?
뭐하는데 implies:
- I have something to do with you.
- I'd like you to do something. "
- (or just simply) I'm curious.
If someone does something instead of what they're supposed to do, you can say "뭐하는데?! What are you doing?! (That's not what you're told to do!)"
나 졸린데 커피 좀 사다줄 수 있어? I'm sleepy, could you please buy me a cup of coffee?
This one is what you're told about.
And about the last two examples Hoon mentions, those are the different word, -는 데.