Maladaptive Daydreaming: where wild minds come to rest
That's not how it works. The brain is an organ, not a muscle. It doesn't have lactic acid. Lactic acid builds up because a muscle is being used and the lactic acid is what the body uses to build muscle mass. When you work out, it tells the body that you need more strength and therefore need more muscle mass. This most definitely does not happen in the brain and has very little to do with oxygen.
Also, daydreaming isn't the same as being asleep as the rest of your body is functioning as it does when you're awake. Sleep isn't just about not being aware of what's around you, but rather has to do with a lot of chemical reactions and the entire body slows down. Even if daydreaming was like sleep, if that were to cause the migraines then everyone would have one when they woke up in the morning.
Though, the idea that MDD and migraines might have a correlation is interesting. I am migraine prone, though most of the time it seems to be food-based. Certain chemicals, especially preservatives, cause pain. So does chocolate. Neurologists all say that this is normal.
Dehydration can also lead to migraines. I know that sometimes I won't drink enough water when I daydream. I always assumed that was the cause of my headaches when I haven't eaten anything that causes them. I wonder if this happens to others.