How would you go on creating a Role System with increasing chances?

So im making a Squid Game like game and im adding guards, i could easily just math.random through players, but i want to add chances, like who ever wins gets a chance to get guard and then the game picks the guard. Im thinking of having at most 16 guards. So if there is 4-12 players only 2 guards, 13-20players 5 guards ,21-25 players 8 guards. 26-30 players 12 guards, 31-40. 16 guards. and once a round is done the guards chance resets to the average chance - (chance gained by winner/amount of guards).

If you want to do influenced role picking - you might want to do a table with every player put in there once, but players you want to have higher chances, could be put in multiple times. You can then math.random through each player until you have enough players chosen.