Host two web sites under same domain name in IIS 8.5

I have two web sites, one is a ReactJs frontend and the other is a .net Core web API. I want to host ReactJs site under www.mydomain.com and API under www.mydomain.com/api. I created a virtual directory (converted to an application) called api and put the .net Core code in there, but React treats www.mydomain.com/api as part of React site. How can I achieve the above? Thanks