If the VM already exist and I do not confirm to overwrite a second VM with the same name will be created.
Then this request get an array instead a string
$VMNetworkAdapter = Get-VMNetworkAdapter -VMName $VMName
$VMNetworkAdapterName = $VMNetworkAdapter.Name