TFT with arduino uno

I have recently been making an Arduino thermostat with a tft shield. It has a temperature sensor attached to A5 which works fine. The issue is when I try to use any of the other available pins which are 2,3 and A4 I can not get them to do anything. If anyone has a solution please help me out.

Which Arduino ?
Which TFT shield ?
What sketch ?

Arduino uno

https://www.ebay.com/itm/2-4-TFT-LCD-Display-Shield-Touch-Panel-ILI9341-240X320-for-Arduino-UNO-MEGA-ASS/184178768643?hash=item2ae1e8fb03:g:SXoAAOSwJ5BeTN2d

And the sketch is not finished so I have not added the thing that needs the other pins but whenever I try to change the pin that the sensor is attached to it does not work.

#include <OneWire.h>
#include <DallasTemperature.h>
#include <Adafruit_GFX.h>
#include <MCUFRIEND_kbv.h>
#include <Fonts/FreeSans9pt7b.h>
#include <Fonts/FreeSans12pt7b.h>
#include <Fonts/FreeSerif12pt7b.h>
#include <FreeDefaultFonts.h>
#define ONE_WIRE_BUS A5
#define BLACK 0x0000
#define RED 0xF800
#define GREEN 0x07E0
#define WHITE 0x000FFF
#define GREY 0x8410
#define BLUE 0x0000FF
float Celcius=0;
int Fahrenheit=0;
MCUFRIEND_kbv tft;
OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);
void setup(void)
{
uint16_t ID = tft.readID();
if (ID == 0xD3D3) ID = 0x9481;
tft.begin(ID);
tft.setRotation(45);
sensors.begin();
}
void loop(void)
{
sensors.requestTemperatures();
Celcius=sensors.getTempCByIndex(0);
Fahrenheit=sensors.toFahrenheit(Celcius);

tft.fillScreen(BLACK);
tft.fillRect(0, 0, 320, 110, RED);
tft.fillRect(0, 110, 320, 130, BLUE);
tft.setFont(&FreeSans9pt7b);
tft.setTextColor(WHITE);
tft.setCursor(80, 90);
tft.setTextSize(6);
tft.print(Fahrenheit);
tft.print("F");
tft.setCursor(65, 144);
tft.setTextSize(2);
tft.print("Fan Control");
delay(7000);
}