It's safe because of a mechanism called escrow. Once you understand that the rest should make sense.