Best advice if you want to make sure this is legally correct is to go and see a solicitor preferably one who specialises in inheritance and capital taxes. You'll need to register a charge against the property as that will be effectively what you are setting up.
The perils of getting something slightly wrong and you ending up with a tax liability are far worse than the money you'd spend getting the agreement drawn up professionally now.