I think you got it correct now. But your writting is only a bit incorrect if I may say so.
just adds on everytime the random number is selected.
Yes this is true in one way but the correct sentence would be that it adds everytime no matter the randomnumber. The randomnumber just defines the random index (for example when you throw the dice you don't know what number you will get, that's what the random number does, it gives a random INDEX of the array which actually represents your dice number and then adds the frequency SAYING , OK THIS NUMBER APPEARED SO JUST INCREMENT THE COUNTER OF THAT NUMBER. The counter is actually the frequency and yes you can say that there are 6 counters in your array since for each index you are incrementing a let's say special counter every time the specific number occurs.