I'm not sure whether you are wanting to do the supported Enterprise version, or a Professional version, that can be free, or alternately you can pay for a licence for the USB device to store it legally.
Either way you first need to get a Windows 10 iso downloaded from Microsoft's site.
Microsoft has a tool for this, or you can manually grab it via their site.
I'm not feeling overly well today, so rather than type out a tonne of instructions just now, I'll wait till I'm feeling better and post an article on this at a later date.
In the meantime, here is an online article that can walk you through how and what to do:
Stuck using a PC with an older operating system? Not if you know how to run Windows 10 or Windows 11 from a flash drive.
au.pcmag.com
Or if you'd rather get advice from the horses mouth per se, then read here:
Windows To Go is a feature in Windows 10 Enterprise and Windows 10 Education that lets you create a workspace that can be booted from a USB-connected drive.
docs.microsoft.com
Regards,
Regedit32