How to upgrade MSbuild version in Azure pipeline?

I have an angular UI and API build which builds fine in local (Visual studio 2019). But in Azure pipeline it fails with below error. In pipeline tasks I cannot find any options to upgrade/downgrade the SDK version nor the MSBuild version. Definitely there should be an option somewhere I am unable to find. Can someone please throw some light?