How are release codenames chosen?
The Ubuntu Wiki has lots of information about the naming system at https://wiki.ubuntu.com/DevelopmentCodeNames. According to Mark Shuttleworth, the "Adjective Animal" system started as a joke and stuck. It's Mark that announces the new names, usually on his blog at http://www.markshuttleworth.com/
Note: this answer is primerally aimed at Why is Ubuntu 16.04 LTS Xenial Xerus? which was marked as a duplicate of this question before I could finish my answer.
Ubuntu codenames follow the form <adjective> <animal>, this started as a joke but it stuck. After Breezy they also decided to move upwards through the alphabet to make things less confusing. At the time they said they "might skip a few letters" but they have only actually done that once (from Breezy to Dapper). Often the first part of the codename is used on it's own (most notablly in the apt repos).
The adjective sometimes says things about the goals of the release. LTS releases tend to have an adjective that brings feelings of strength and stability. Earlier non-lts releases tended to use adjectives that have a more bleeding edge feel while more recent ones seem to have moved to more neutral adjectives.
Compare:
Dapper, Hardy, Lucid, Precise, Trusty, Xenial (lts releases)
Warty, Hoary, Breezy, Edgy, Feisty, Gutsy, Intrepid, Jaunty, Karmic, Maverick, Natty, Oneiric, Quantal, Raring, Saucy, Utopic, Vivid, Wily (non-lts releases)
Marks reasoning on the name Xenial Xerus can be found at http://www.markshuttleworth.com/archives/1479
What fortunate timing that our next LTS should be X, because “xenial” means “friendly relations between hosts and guests”, and given all the amazing work going into LXD and KVM for Ubuntu OpenStack, and beyond that the interoperability of Ubuntu OpenStack with hypervisors of all sorts, it seems like a perfect fit.
And Xerus, the African ground squirrels, are among the most social animals in my home country. They thrive in the desert, they live in small, agile, social groups that get along unusually well with their neighbours (for most mammals, neighbours are a source of bloody competition, for Xerus, hey, collaboration is cool). They are fast, feisty, friendly and known for their enormous… courage. That sounds just about right. With great… courage… comes great opportunity!