Renaming pins in sketch
If I understood your question correctly, you're looking for something like this:  

static const byte PIN_NUMBER[4] = { 0, 2, 5, 6 };
static const char *PIN_NAME[4] = { "A", "B", "C", "D" };

// and use them like this:

void Log(byte index)
{
  byte val = digitalRead(PIN_NUMBER[index]);
  Serial.print(PIN_NAME[index]);
  Serial.print('|');
  Serial.println(val);
}

void setup()
{
  for (byte i = 0; i &lt; 4; ++i) pinMode(PIN_NUMBER[i], INPUT);
}

void loop()
{
  Serial.println("PIN|VALUE");
  for (byte i = 0; i &lt; 4; ++i) Log(i);
  delay(1000);
}


Also, in the special case of "A", "B", "C", "D" as pin names, you don't really need the PIN_NAME array, instead of  

Serial.print(PIN_NAME[index]);


you can use:  

Serial.print('A' + index);