You don’t get to “quit your mortage”. You borrow $X to buy a place, then pay back $Y/month, of which some fraction goes to pay back the principle and some other fraction to pay the interest.
In two years, you sell the house for $Z. You typically give at least 3% of that to a real estate agent. The bank gets back ($X - principle paid back). You get the rest. That amount may be more or less than your down payment.
Putting your numbers in: Say your brother pays 20% down on a $15K condo, his down payment is $3K. There are other costs associated with buying a place, he may wish to get it inspected ($200), there may be closing costs and other fees charged by the bank he’s dealing with, and he may decide to buy a lower interest rate by paying “points”. Let’s round that all off and say $800 in extra closing costs.
So he’s out $1.5k for the down payment plus $800 in closing costs for an outlay of $3.8K. He borrows $12k. By the end of 2 years, he’s payed back $500 of that principle (making minimum payments on a 30 year note, you’re mostly paying interest the first couple of years).
Then let’s take 2 selling scenarios. First, he sells it for $20k, because property prices have shot up. He pays $600 to the realtor (3%), $11.5K to the bank to take care of his mortage ballance, and pockets $8.9k. Take out the $3.8K he started with, and his profit on the transaction is $5.1K (results not typical).
For the second scenario, he sells for $15k, because property prices are stagnant. He pays around $450 to the realtor, $11.5k to the bank, and pockets around $3k, which is less than the $3.8k he put into the place. (Of course, over the course of the two years he’s gotten some extra money back from the government by writing off the interest he’s been paying).
All numbers other than yours are estimates, and your brother has to do his own research to fill in the blanks.
The real advantage of knowing that you’re selling in 2 years is that you can get a 2 year adjustible rate mortage (where you and the bank agree that they can raise your interest rate in 2 years time), which will typically be a much lower rate than a 30 year fixed rate, and you know that you are never going to have to actually pay that increased rate because you’re going to sell. The disadvantage is that you can end up losing money if the market hits a short-term peak.