Can you put two people down on the Mortgage and one person on the deeds so the person on the deeds takes advantage of the house being under 317K and doesn't pay any Stamp duty being a first time buyer ?
If the other person is actually contributing to the purchase and technically has a beneficial interest in the property then doing this to avoid (evade?) SD could be dodgy as far as I know. See these two Revenue press releases and ask your solicitor: