It means both “stick to or keep together” and “separate from or break apart”. Often the only way to determine which of the diametrically-opposed meanings is intended is by examining the context, and if the context is ambiguous, it can be impossible.
The root word derives from nail (the thing or action that causes one thing to be joined to another, and that in the process, tends to split things apart). Cloves are so-called because of the resemblance to nails. Garlic cloves are so-called because of their splitting and breaking.