To create a Compound in the Main Menu select New Entity - > Build - > Compound.
You can create a compound from a list of shapes.
The Result will be a GEOM_Object (COMPOUND).
TUI Command: geompy.MakeCompound(ListOfShape)
Arguments: Name + List of shapes.
Advanced option: Set presentation parameters and sub-shapes from arguments.
Example:
Our TUI Scripts provide you with useful examples of creation of Advanced Geometric Objects.
More details:
Perhaps you ask yourself : What's the difference between partition, compounds and fuse operation ?