The clear answer is that you can do this, but on SK, not on UA, since UA doesn't have the flights you need.
Here are the rules. See the rule for "Open Jaw". An open jaw trip involves exactly what you propose: arriving in one city and returning from another.