I am building a couple more sites to add to my portfolio but I have no money to buy domain names for them so I want to temporarily host them on my portfolio eg: myportfolio.com/subsite1

I am unsure how to go about this since these other websites have a root based link structure (href="/page1"), so the "/" would take it to the root if it had its own domain, but since I am hosting it on my portfolio site it would go from portfolio.com/subsite1/page1 - the "/" would take you to portfolio.com, but I want the "/" in my sub site to take me to portfolio.com/subsite1.

how would I go about doing this.... could the htaccess file do this?