GnuPG for Windows 7 stores all its key files in %USERPROFILE%\AppData\Roaming\gnupg, but I wanted to change this path, say to D:\Profile\GPG, so that the files can easily be backed up.
It turns out, there are quite a few different methods to change the path: changing the default keyring location in windows.
I chose to change the config file %USERPROFILE%\AppData\Roaming\gnupg\gpg.conf and added these lines:
no-default-keyring primary-keyring D:\Profile\GPG\pubring.gpg secret-keyring D:\Profile\GPG\secring.gpg trustdb-name D:\Profile\GPG\trustdb.gpg keyring D:\Profile\GPG\pubring.gpg
Then I moved all the key files to the new location, leaving only gpg.conf in the original path.
Edit: After reconsidering my backup, I set the environment variable GNUPGHOME to D:\Profile\GPG instead of changing gpg.conf. This way, all files related to GPG including the configuration are stored in one location.