change groups structure