Hello,
Thank you for posting in Q&A forum.
You can use the Windows command Mklink to create a symbolic link pointing C:\swapfile.sys to another partition.
Please refer to the following link for specific steps: How to move Pagefile.sys and Swapfile.sys to another drive in Windows 8/8.1 or 10 (download3k.com)
It will show you how to move Swapfile.sys to another drive. You will need administrator rights to do this, so have your administrator credentials ready.
I hope the information above is helpful.
Best Regards,
Yanhong Liu
============================================
If the Answer is helpful, please click "Accept Answer" and upvote it.