how to count files in each folder of TF card on YX5200 DFPlayer module

Hi Guys. First post for me and a question if any of you can please help.
I using a one of the YX5200 modules and controlling it from a Arduino Nano.
I have three folders on the card and currently a single file in each. In response to a input on one of three input lines on the Nano, I play a file from the corresponding folder.
All well and good and reliable.
I now want to play add more than one file in each folder and play different ones each time but, to do that, I need a way to count how many files are in each of the folders. It may well be that each folder will have a different number of files.
So I need a way to count the number of mp3 files in each of the folders at the start of my program.
Any ideas anyone?

Take a look here:

There you will find a library and example code.
Close to the end of the page there is:

Serial.println(myDFPlayer.readFileCountsInFolder(3)); //read file counts in folder SD:/03

This may be what you need.