When your offer is accepted you do not yet own the property, it is only sold 'subject to contract'. The agreement is only legally binding when contracts exchange, and you only finally own the property when, upon completion, the legal transfer occurs. The process to achieve this is known as conveyancing.
The starting point of conveyancing is when the buyer's solicitors draws up the contract. This contains important details about the property - what you are buying - and includes information such as the fixtures and fittings, the boundaries and any legal restrictions associated with it, and critically the price and the target completion date.
Although the contract is drawn up by the buyer's solicitors, its contents must be agreed to by both the buyer and seller. When they are both happy with the contract, both sides sign final copies and passing them to each other; this is the exchange of contracts. The agreement is now legally binding. The deposit is generally paid at this point and the date for completion is set.
On the day of completion, the funds are transferred from the buyer to the seller. Legal documentation formally transfers ownership to the buyer. It's yours, the seller moves out, you get the keys and move in.