Find the latest Mono and XCode version first. Then manually set them using:
/bin/bash -c "sudo $AGENT_HOMEDIRECTORY/scripts/select-xamarin-sdk.sh 6_12_10"
/bin/bash -c "echo '##vso[task.setvariable variable=MD_APPLE_SDK_ROOT;]'/Applications/Xcode_13.0.app;sudo xcode-select --switch /Applications/Xcode_13.0.app/Contents/Developer"
Then build using:
mono
'/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/msbuild.dll'
/p:Configuration=$(BuildConfiguration)
/p:Platform=iPhone
'<path to project>'
This will help you add the image.