Microsoft recommend installing on C; that’s good enough for me.
However, the packages can go wherever you like; just create the folder of your choice and, if they already exist on C, copy them to your new folder.
Then point the sim to your new folder; no need to edit any files. Check it all works, and delete the original packages (just the packages, not the containing folders); the sim expects to find them there I think. They will remain empty so won’t take up any of your storage space.