icacls "C:\Users\NewName" /grant %username%:F /t
Then run:
To perform this action, you need and access to a separate Administrator account . You cannot rename the folder of the account you are currently logged into. windows 10 change user name folder
(This grants full control.)
Now that the folder is physically renamed, you must tell Windows where the new folder is located. windows 10 change user name folder