(a) If at any time during the election any qualified voter shall appear at the polls for the purpose of stating that any person who has voted is an illegal voter in the precinct, that person shall be admitted to the election room and shall appear before a commissioner of election to make an affidavit explaining why he or she believes the accused to be an illegal voter.
(b) All affidavits alleging illegal voting shall be placed in a strong and durable envelope by the commissioners of election. The envelope shall be securely sealed and each of the commissioners shall endorse his or her name on the back of the envelope. At the close of the count the envelope shall be delivered to the clerk of the circuit court in accordance with section sixteen, article five of this chapter and section eight, article six of this chapter. The clerk of the circuit court shall carefully preserve the envelope containing the affidavits and deliver it, with the seal unbroken, to the prosecuting attorney in the county. The prosecuting attorney shall proceed as if it had been made before him or her.