All your asking, really, is if its possible to upgrade a swordman to a guard, but still cost the swordsman. The answer is yes, of course, but the units will always be called swordsman. Just create an upgrade to research that gives swordsmen the guard's stats. Done!
It's really that easy and you'll never have to pick between swordsmen and guards. You will have to figure a good cost for the upgrade though...