Beginner question on pins

The 5 pin is like an SPI device. It can be interfaced with the SPI library or "bit banged" SPI.

The other one, with SDA ans SCL, is an I2C device.

The 2 interface types are different. There are libraries to facilitate using the interfaces. For SPI there is the SPI library and for the other there is the Wire library.

Which, exact, backpack do you have? You will need to program for the interface that you have (we can surely help with that once we know what you have). There is no easy way to convert one to the other.