During OS Deployment it's not entirely uncommon to see organizations renaming the local admin directly in the task sequence. There are many options available for doing so, but using a healthy dose of PowerShell is an effective way. 🙂
Using the Rename-LocalUser Cmdlet
Below sample gets hold of the local administrator account from its well-known SID, and then renames that account by piping the object to the Rename-LocalUser cmdlet.
$NewAdminName = "Demo1"
Get-LocalUser | Where-Object { $_.SID -like "S-1-5-*-500" } | Rename-LocalUser -NewName $NewAdminName
Simply add the above script to your task sequence, no need for a package, but don't forget to set the PowerShell execution policy to Bypass.

Hi Johan! We are having an issue lately where the Local Admin Account is getting disabled before MDT LiteTouch Deployment finishes. After the First Reboot of applying the image, it reboots as it normally would and we expect it to login with the local admin account but it gives us a message instead that the local administrator account is disabled. This did not used to happen and the only thing I can think of that has changed is we updated the build of Windows 10 that we are deploying to the 22H2.18 from our VLSC downloads. Any Help here would… Read more »
Most likely a GPO that is coming down and disabling the account. If that's the case, deploy the computer into a staging OU with policies, and as a last step in the sequence, move it to the right OU, and do a final reboot. Here is a guide: https://www.deploymentresearch.com/moving-computers-to-another-ou-during-deployment-webservice-style/