This mostly sums it up,
https://en.wikipedia.org/wiki/Type_syst ... Royal_NavyThere were also many design studies and proposals that didn't get a type number and changing design criteria, weapon and sensor system development, and budget constraints and political whims meant definitions were flexible.
After WWII Frigate designs kept growing and Destroyer designs started to look like cruisers then shrank again, so there was an overlap between them which is why you see mixing of the numbers.
The book British Destroyers and Frigates by Norman Friedman goes into the history of the designs in detail if you want to understand the intricacies of each design.