When bubbles of oil meet they interact in this way to try to reduce the amount of area in contact with the underlying fluid. It's almost like they know how to stay alive longer by organising themselves in this way. Self-preservation exists even in an inanimate object.