Make sure you have DirectX12 set as active. Go to Project Settings → Platforms → Windows → Default RHI → DirectX 12. Nanite only works if DirectX 12 is activated apparently.
Your problem seems to be equal to this one:
So the fix might be the same.