The w5100 uses the SPI bus to communicate with the Mega. The Mega uses D50-D53 for the SPI lines.
D53 is the default slave select, so it must be set to OUTPUT, and normally the libraries that use the SPI set that line HIGH also, even tho it is not mentioned as required to set the SPI bus to master mode.
D51 is the MOSI line. It is the Mega SPI (MOSI) output pin for the SPI bus.
Kinda. D4 is used by the SD card slot on the shield as the slave select. If you plan on using an SD card (or even having one in the slot), don't use that pin. I understand that D2 is used by the w5100 as an interrupt line, so I would avoid it also.
The datasheet for ATmega1280/2560 has the full info on all the uses of all the pins if you are interrested - just
look at the pin names on the package outlines to see how many pins have extra uses! PWM and analog capabilities,
SPI and I2C bus, address/data bus and so forth... Mostly the Arduino platform hides the detail to promote
portability and simplicity.
Note that the SPI pins are also brought out in duplicate on the 6-pin ICSP header, which is good because otherwise they would
be in different places on Uno and Mega. If you want to connect to SPI use that header is possible. If you don't
want to clash with SPI then you have to avoid pins 10..13 (for Uno) and 50..53 (for Mega).