Can I connect a NEO-6M GPS Module and ESP8266 to the same Arduino?
You can use Software serial for this.

and assign pins like
SoftwareSerial mySerial(2, 3); // RX, TX

This is a link for better understanding https://www.arduino.cc/en/Tutorial/SoftwareSerialExample