Can i stop motor rotation using Bluetooth connection and button is pushed

I am using Arduino Nano, Bluetooth module HC-05 and one push button. I want to rotate the motor when it receives signal from the Bluetooth and stop the rotation when the push button is pressed but here the Bluetooth signal should not be disconnected the motor should stop its rotation when Bluetooth is connected and the button is pressed. The problem is when signal is passed through Bluetooth or serial , the motor rotates but when we push the button to stop the rotation the motor doesn't stops. Below is what I tried.

#include <SoftwareSerial.h>
SoftwareSerial Bluetooth(10,6);
const int  buttonPin = 5;    // the pin that the pushbutton is attached to
const int  motorPin = 9;
const int ledPin = LED_BUILTIN;       // the pin that the LED is attached to
int buttonState = 0;         // current state of the button
int Data;
void setup() {

  Serial.begin(9600);
  Bluetooth.begin(9600);
  Bluetooth.println("Send 1 to open LOCK. Send 0 to close LOCK");
  Serial.println("Send 1 to open LOCK. Send 0 to close LOCK");
  delay(1000);
  Bluetooth.println("Waiting for command..."); 
  Serial.println("Waiting for command..."); 
  pinMode(buttonPin, INPUT);
  pinMode(motorPin, OUTPUT);
  pinMode(ledPin, OUTPUT);
}
void loop() {
  // read the pushbutton input pin:
  buttonState = digitalRead(buttonPin);

if (Bluetooth.available())
{  
    Data=Bluetooth.read(); 
    if(Data=='1'){
      Serial.println("Motor rotating");
      Serial.println(buttonState);
      digitalWrite(motorPin, HIGH);
    }

      if (Data=='1' and buttonState == 1){
      Serial.println("Motor stop");
      Serial.println(buttonState);
      digitalWrite(motorPin, LOW);
      digitalWrite(ledPin, HIGH);

    }
    else{;}
}
}

I tried only to control with the push button only which works well. When the button is pushed it motor stops and when unpushed it rotates.

Two things to consider:
The pin mode of buttonPin is INPUT. This means that if you don't have a pull-down resistor on that pin, it will be floating and have random states when the button is not pressed. Much more simple is to use INPUT_PULLUP mode and change the wiring of your button and the logic of your code so that the button pressed state is LOW:

The logic of your code makes it so that the state of the button only takes effect when there is data available from the Bluetooth serial interface.

Two things to consider:
The pin mode of buttonPin is INPUT. This means that if you don't have a pull-down resistor on that pin, it will be floating and have random states when the button is not pressed. Much more simple is to use INPUT_PULLUP mode and change the wiring of your button and the logic of your code so that the button pressed state is LOW:

pert:
The logic of your code makes it so that the state of the button only takes effect when there is data available from the Bluetooth serial interface.

I tried using the data and button state to gather but still it remains the same. I tried the below logic.

if(Data=='1' and buttonState == 0){
      Serial.println("Motor rotating");
      Serial.println(buttonState);
      digitalWrite(motorPin, HIGH);
      digitalWrite(ledPin, LOW);
    }
    
      else if (Data=='1' and buttonState == 1){
      Serial.println("Motor stop");
      Serial.println(buttonState);
      digitalWrite(motorPin, LOW);
      digitalWrite(ledPin, HIGH);

      
    }

Please post your full sketch. Code snippets are not helpful.