If you have "activated" the installed Windows using the product key you used, you may have a problem installing Windows again on the replacement machine they send you... depending on the nature of that product key you used.
If it's an OEM key, it can only be used on the one machine it was used on. It can't be used on another machine.
If it's a retail key, it can only be used on one machine at a time. So you need to "de-activate" it on the current machine before returning it, and then you'll be able to use that key again to freshly install Windows again on the replacement machine when it arrives.
As far as doing a FORMAT of some kind on the hard drive before returning it, if you haven't put any of your own proprietary data on it yet I wouldn't worry about it. They're going to re-load the hard drive with whatever they put on it whenever selling a new machine no matter what you do. So just be sure to "de-activate" the product key if you used a retail key and if you've already activated your installation of Windows on this machine.
NOTE: MS is reasonably reasonable in understanding that people sometimes forget to de-activate a Windows installation before doing a hardware upgrade (or swap, as in your case). So the automated activation that is attempted from the second install will likely be rejected by their Registration Server. You'll then have to use the "activate by phone" method, and possibly have to speak to someone who will manually "void out" your previous activation using the retail product key, and then will give you some new numbers to enter into the onscreen "phone activation" window in order to accomplish the new activation successfully.