When creating a task sequence to deploy an operating system. It’s possible to ask for a computername when running the task sequence on a unknown computer, for instance a new computer.
Advertise (‘NO’ mandatory assignment) the task sequence to the collection: All Unknown Computers.
Click on thumbnails for larger image.
Right click on the collection: All Unknown Computers and select: Modify Collection Settings.
Go to tab: Collection Variables click on the new variable icon. Give the variable the name: OSDcomputerName and leave the value empty.

When booting the task sequence, on a new computer (or remove the computer first in sccm) the following screens will appear:

When the following screen appears, double click on the variable and give the right computername for the new computer.
The task sequence will install the new computer with the new given computername.