From Halopedia, the Halo wiki
Were you looking for the Flood, a zombie-like species inhabiting the Halos or Infection, a multiplayer gametype staring in Halo 3?
Zombies is a gametype in Halo 2 based on the Slayer gamemode. In the gametype, red players are cast as survivors, whereas green players are the titular zombies, who must hunt down and kill the remaining survivors, at which point those survivors become zombies themselves. The gametype relies on an honour system; players are expected to manually switch teams upon death, and to equip the appropriate weapon for their team upon spawning. Initially, the Zombies gametype was a fan-made variant, but it was later officially distributed by Bungie, in an Official Xbox Magazine demo disc, making for a rare piece of Halo 2 downloadable content.
In Halo 3, the Zombies gametype became its own dedicated gamemode: Infection, wherein the rules of the mode are enforced by the game, rather than relying on an honour system. Infection (or the identical gamemode, Flood) has since appeared in every subsequent first-person instalment of the franchise with a competitive multiplayer, and has been cemented as one of the franchise's most popular modes.
The basic rules of Zombies involve two teams: a small starting green (or blue in some cases) team, who comprise the titular zombies, and a relatively large red team, the survivors. All players start with a Magnum and Energy Sword, and there are no shields. Upon spawning, red team players must equip the Magnum, while green team uses the Sword. Whenever a red team member is killed, they must switch to the green team. The ultimate goal for the survivors on red team to last as long as possible without getting killed by the zombies, while the zombies' goal is to infect all remaining humans.
The mode originated in Halo 2 custom games as a player-made variant of the Slayer gametype. This mode was based on honour rules, meaning players were trusted to manually switch teams when they were killed. In June 2005, this variant was distributed officially, in Issue 45 of the Official Xbox Magazine. The mode was included in a demo disc bundled with the magazine, and could be downloaded to the Xbox's hard drive and then played in Halo 2 as a game variant of Slayer, like any other.