From ASP.NET Core 3.0+ and visual studio 19 version 16.3+ You will find section in project .csproj file are like below-
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>
There is no AspNetCoreHostingModel property there. You will find Hosting model selection in the properties of the project. Right-click the project name in the solution explorer. Click properties.
Click the Debug menu.
Scroll down to find the Hosting Model option.
Select Out of Process.
Save the project and run IIS Express.
UPDATE For Server Deployment:
When you publish your application in the server there is a web config file like below:
change value of 'hostingModel' from 'inprocess' to 'outofprocess' like below: