Question about on/off led with (RFID module)

but i cannot close the led by passing the card for the second time.

Why can't you?

       if(serNum[0] == 163 )  {
                          Serial.println("card");
                          cardState = !cardState;
                          digitalWrite(card,cardState);
                       }

Where cardState is a boolean, initialized to false.