You can’t upgrade a gateway with this feature, right now the PowerShell script is only applicable for installing DataGateway.
Adding Gateway Members to newly created cluster is not supported yet.
The "Add-DataGatewayCluster" script will install the gateway cluster that must be `3000.37.35` (April 2020) or higher gateway version.
Make sure you have the PowerShell version 7 because these scripts only work with version 7 and above.
You have to run the script in the PowerShell in Admin mode.
If you want to overwrite the existing gateway configuration on the local machine and configure a new one, use -OverwriteExistingGateway in "Add-DataGatewayCluster" script.
By default, the "Add-DataGatewayCluster" script will install the gateway in Power BI default tenant region, if you want to change the region then you have to provide the correct region which you can get from the "Get-DataGatewayRegion" module.