code: public function load(ObjectManager $manager)
      {
          // Normal user
          $group = new Group();
          $group->setName('User');
          $group->setRole('ROLE_USER');
          $manager->persist($group);
          $this->addReference('user-group', $group);
  
          // Administrator
          $group = new Group();
          $group->setName('Administrator');
          $group->setRole('ROLE_ADMIN');
          $manager->persist($group);
          $this->addReference('admin-group', $group);
  
          $manager->flush();
      }
docs: Load data fixtures with the passed EntityManager
  
  @param \Doctrine\Common\Persistence\ObjectManager $manager