Check that you have latest windows updates that allows WSL 2 and then Open an admin Powershell instance and run the following commands:
- Enable WSL
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
- Enable ‘Virtual Machine Platform’
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
- Set WSL 2 as default
wsl --set-default-version 2