|Okay, first glance:|
1) FOR will tell you the size in bytes, not kilobytes.
2) 2^20 is not 1024000, it is 1,048,576
3) SET does not have a '\' operator
4) SET /A won't save any variable if it's part of a pipe
5) You're trying to subtract the total number of megabytes from the current byte counter, instead of subtracting the total number of bytes in a megabyte
6) SET uses signed 32-bit integers, so expect the script to break if the total byte count should ever go above 2^31-1 (2GB or up, basically). This can be incredibly easy to do, because you only ever subtract 1MB per pass of the loop.
Perhaps you should just use a third party program? Like WinDirInfo?