Add a `getModel()` method to modules, elements and hybrids (see #6492)