Create a new Device configuration file
Navigate to intune -> Home->Devices->Manage Devices->configuration
Create a new Policies
Platform: Windows 10 and later
Profile Type: Template
Select: Custom
Go to configuration settings
Add new row
Name: Admin
OMA-URI:
./Device/Vendor/MSFT/Accounts/Users/Admin/Password
Data Type: String
Value: Lost@12345
Add one more raw for adding local admin group
Name: Adding admin group
OMA-URI: ./Device/Vendor/MSFT/Accounts/Users/Admin/LocalUserGroup
Data type: Integer
Value: 2
Save and apply to the configuration file to Device groups