The artifact published in azure pipeline provides dowload url to get the files. You can get the download url directly from the build summary portal. See below:
Go the published artifacts-->Click the 3dots
of the file you want to download
You can call the download url directly to read the xml file in your code. See below example in powershell script:
$url = "https://dev.azure.com/{org}/_apis/resources/Containers/{containerId}/{artifactName}?itemPath=artifactName%2Fbuild.xml"
$PAT="Personal access token"
$base64AuthInfo= [System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes(":$($PAT)"))
$xmlContent = Invoke-RestMethod -Uri $url -Headers @{authorization = "Basic $base64AuthInfo"} -Method get
If you donot want to get the download url from the UI portal. You can call Artifacts - Get Artifact to get the container id. Then you can get the download url for the xml file after you get the container id.
GET https://dev.azure.com/{organization}/{project}/_apis/build/builds/{buildId}/artifacts?artifactName={artifactName}&api-version=6.0
See below example result from above rest api.
Download url:
https://dev.azure.com/{org}/_apis/resources/Containers/{containerId}/{artifactName}?itemPath={artifactName}%2F{xmlfileName.xml}