There are two main options.
Becoming "Joint Tenants" is ideal if you are a couple, particularly if you're married. It means you will jointly own the whole of the property. If the worst happens and one of you should die, the ownership will automatically pass to the other.
The second option is to hold the property as "Tenants In Common", which means each of you owns an agreed proportion of the property. You might decide that you own an equal share of the property, or (for example) that one of you will own 70% and the other 30%. Should one of you die their proportion will pass to whoever is specified in the deceased person's will.
A joint purchase should always be made with the expert advice of a solicitor.