If there is multiple check-boxes with same ids and you have to select the next check-box which is not selected/checked.
For such scenario you can refer below script -
stnewrecord'is class of check-box. Script will store number of check-box, and according to that loop will follow. It will check whether check-box is checked or not if not it will check else move to next step.
This is xpath of check-box. 'i' is position, it will increase on each iteration.