Start by following this guide: https://docs.microsoft.com/en-us/windows/wsl/install-win10. Another nice resource is the blog post Setting up WSL2 and Oh My Zsh.
When running the dism.exe
commands during setup you may get an error saying that you need elevated permissions, even if you run PowerShell as admin, you then need to run this command first to get elevated permissions:
Start-Process powershell -Verb runAs