HELP ME WITH MOVEMENT

so i made a movement script and when u spin and go forward it goes the original forward and not the new forward, how do i fix this?

using System.Collections;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
//rb.AddForce(0, 0, forwardForce * Time.deltaTime);
//if (Input.GetKey("space"))
public class Movement : MonoBehaviour
{
public Rigidbody rb;
    public float forwardForce = 1000f;
    public float turnForce = 50f;
    // Start is called before the first frame update
    void Start()
    {
       
    }

    // Update is called once per frame
    void Update()
    {
        if (Input.GetKey("w"))
        {
            rb.AddForce(0, 0, forwardForce * Time.deltaTime);
        }
        if (Input.GetKey("d"))
        {
            transform.Rotate(Vector3.right, turnForce * Time.deltaTime);
        }
        if (Input.GetKey("a"))
        {
            transform.Rotate(Vector3.right, -turnForce * Time.deltaTime);
        }
    }
}

Your code adds force to the z axis of the rigidbody in world space, so it won’t matter which way you face. Try adding force to the transforms local forward:

        if (Input.GetKey("w"))
        {
            rb.AddForce(transform.forward * Time.deltaTime);
        }