Royal Navy ships were named according to one of several standard systems; class names varied according to the system:
Capital ships such as battleships, battle cruisers and aircraft carriers always bore traditional and for the most part, inspirational names. Here's a sampling
Classes were named after a "name ship" of the class. The British usually tried to give ships of a class similar names; for instance "Lion" and "Tiger" usually went together, as did "Couraegous", "Glorious" and "Furious" and the distinctly British combination of "Invincible", "Inflexible", "Indomitable", and "Indefatigable"
"Letter Classes" are usually used for Destroyers and Submarines (The class name is a letter of the alphabet; all ships in the class have names starting with this letter.
"B"-class destroyers -- HMS Basilisk, Beagle, Blanche, Boadicea, Brazen, Bulldog.
"D"-class cruisers -- HMS Danae, Dauntless, Dragon, Durban, Diomede.
"U"-class submarines -- HMS Upholder, Undine, Unity, Ursula, Unbeaten, Undaunted, Upright.
"Generic Classes" were usually used for Cruisers and some Destroyers. The class has some generic name and each ship in the class is named after a specific example of the class name. Examples:
Weapon-class destroyers -- HMS Battleaxe, Broadsword, Carronade, Culverin, Crossbow, Halberd, Musket, Tomahawk.
Tribal-class destroyers -- HMS Ashanti, Gurkha, Huron, Iroquois, Maori, Mohawk, Sikh, Zulu.
Town-class destroyers -- HMS Leeds, Campbeltown, Lancaster, Lincoln, Bath, Brighton, Newport.
Hunt-class escort destroyers -- HMS Berkeley, Exmoor, Southdown, Tynedale.
Cathedral-class cruisers -- HMS Exeter and York.
County-class cruisers -- HMS Cornwall, Cumberland, Kent, Dorsetshire, Shropshire, Norfolk, Suffolk, Sussex.
Flower-class sloops -- HMS Foxglove, Lupin, Rosemary.
Once a ship had been named, the name was almost never changed. Remainder of a belief that the ship's name was its "soul", changing the name was thought to bring bad luck to the ship. The major exceptions were of captured (or otherwise acquired foreign-built) ships, which were re-named if their name duplicated that of an existing British ship or sounded very "un-British".