When things belonging to different owners have been united so as to form a single thing, and cannot be separated without injury, the whole belongs to the owner of the thing which forms the principal part; who must, however, reimburse the value of the residue to the other owner, or surrender the whole to him.