code: private void addChildrenForRolesNode(String ouItem) {
  
          try {
              List<CmsRole> roles = OpenCms.getRoleManager().getRoles(m_cms, ouItem.substring(1), false);
              CmsRole.applySystemRoleOrder(roles);
              for (CmsRole role : roles) {
                  String roleId = ouItem + "/" + role.getId();
                  Item roleItem = m_treeContainer.addItem(roleId);
                  if (roleItem == null) {
                      roleItem = getItem(roleId);
                  }
                  roleItem.getItemProperty(PROP_NAME).setValue(getIconCaptionHTML(role, CmsOuTreeType.ROLE));
                  roleItem.getItemProperty(PROP_TYPE).setValue(CmsOuTreeType.ROLE);
                  setChildrenAllowed(roleId, false);
                  m_treeContainer.setParent(roleId, ouItem);
              }
          } catch (CmsException e) {
              LOG.error("Can not read group", e);
          }
      }
docs: Add roles for given role parent item.
  
  @param ouItem group parent item