If you aren't going to count Frederick as a Duke of York because he also held the Duke of Albany title then there haven't been 8 creations but 5.
You can't have it both ways - either he was Duke of York and one of the 8 creations, or there were only 5 creations.
He is always listed as a Duke of York and therefore is one of the 8 creations. His additional title is irrelevant.
He died without legitimate issue (just as did Richard the Prince in the Tower) and therefore your statement that Richard is the only one is wrong.
<...>
That is not entirely correct. There were 8 creations of the Duke of York title
and 3 creations of the Duke of York and Albany title.
The creations of the Duke of York title were the following.
1st creation (1385) - for Edmund of Langley, younger son of Edward III
2nd creation (1474) - for Prince Richard. younger son of Edward IV (one of the Princes in Tower)
3rd creation (1494) - for Prince Henry (future Henry VIII), the younger son of Henry VII
4th creation (1605) - for Prince Charles (future Charles I), the younger son of James I
5th creation (1644) - for Prince James (future James II), the younger son of Charles I
6th creation (1892) - for Prince George (future George V), the younger son of Edward VII
7th creation (1920) - for Prince Albert (future George VI), the younger son of George V
8th creation (1986) - for Prince Andrew, the younger son of Queen Elizabeth II
In between the 5th and 6th creations (between 1685 abd 1892), the title was not created separately but as part of Duke of York and Albany title (which is one title, not two).
There were 3 creations of Duke of York and Albany title:
1st creation (1716) - for Prince Ernest Augustus, the younger brother of George I
2nd creation (1760) - for Prince Edward, the younger brother of George III
3rd creation (1784) - for Prince Frederick, the younger son of George III
After Prince Frederick's death without legitimate issue, the title (Duke of York and Albany) became extant and was available for recreation (both as one title, and as two separate titles - which is what happened).
Whenever you find mention of Prince Frederick as "Duke of York" - only, that is an incorrect reference: he was Duke of York and Albany.
The title "Duke of Albany" is indeed suspended under 1917 Title Depravation Act. It had 7 creations, plus 3 creations as part of the "Duke of York and Albany" title.
The current Heir to the "Dukedom of Albany" is Sebastian Hubertus, Prinz von Sachsen-Coburg und Gotha (the great-grandson of Prince Charles, 2nd Duke of Albany, the last de-facto holder of the title).