@lakshmi Thanks for reaching here! You may try using Azure PowerShell task, but just remain newline symbol, the value won’t be in multiple lines, for example:
$webAppName="XXX"
$resourceGroupName="XXX"
$newAppSettings =@{"newSetting01"="newValue01";"newSetting02"="t1\nt2\n123456"}
Set-AzureRmWebApp -AppSettings $newAppSettings -Name $webAppName -ResourceGroupName $resourceGroupName
You may refer to this article: Apply / Update application settings for Azure App Service using PowerShell
Let us know.