I can't make my character walk up stairs or slopes using the following code and rigidbody. Can someone help?

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Movement : MonoBehaviour
{
    public float speed, jumpSpeed;
    public Camera cam;
    public Transform camFollow;
    public float mousesens;
    private float rotX, rotY;
    public Rigidbody rb;
    public BoxCollider bcol;
    public bool grounded = true, stairHit;
    public bool isMoving = false, isJumping = false, pressed = false;
    public Vector3 movement, slopeMoveDirection;
    public RaycastHit slophit; 


    void Start()
    {
        Cursor.lockState = CursorLockMode.Locked;
        
    }

void Update()
    {
        if (rb.velocity.x != 0 || rb.velocity.z != 0)
        {
            isMoving = true;
            Debug.Log("moving");
        }
        else
        {
            isMoving = false;
            Debug.Log("still");
        }
        //look where player is looking
        cam.transform.position = camFollow.position;
        rotY += Input.GetAxis("Mouse X") * mousesens;
        rotX -= Input.GetAxis("Mouse Y") * mousesens;
        rotX = Mathf.Clamp(rotX, -90, 90);
        transform.eulerAngles = new Vector3(0, rotY, 0);
        cam.transform.eulerAngles = new Vector3(rotX, rotY, 0);

        //jumping
        grounded = !Physics.BoxCast(bcol.transform.position, bcol.bounds.extents, Vector3.down, bcol.transform.rotation, Mathf.Infinity, LayerMask.GetMask("Ground", "Stairs"));
        if (Input.GetButton("Jump") && grounded == true)
        {
            rb.velocity = new Vector3(0, jumpSpeed, 0);
        }
    }
            void FixedUpdate()
            {
                //running
                if (Input.GetKey(KeyCode.LeftShift) == false)
                {

                    if (Input.GetKey("w"))
                    {
                        rb.AddRelativeForce(0, 0, speed);
                    }
                    else {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }

                    if (Input.GetKey("s"))
                    {
                        rb.AddRelativeForce(0, 0, -speed);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }

                    if (Input.GetKey("d"))
                    {
                        rb.AddRelativeForce(speed, 0, 0);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }


                    if (Input.GetKey("a"))
                    {
                        rb.AddRelativeForce(-speed, 0, 0);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);

                    }

                }
                else
                {
                    if (Input.GetKey("w"))
                    {
                        rb.AddRelativeForce(0, 0, speed * 3);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }

                    if (Input.GetKey("s"))
                    {
                        rb.AddRelativeForce(0, 0, -speed * 3);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }

                    if (Input.GetKey("d"))
                    {
                        rb.AddRelativeForce(speed * 3, 0, 0);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }

                    if (Input.GetKey("a"))
                    {
                        rb.AddRelativeForce(-speed * 3, 0, 0);
                    }
                    else
                    {
                        rb.velocity = new Vector3(0, rb.velocity.y, 0);
                    }
                }


            }
        }

For slope: write a method, that check normal direction of mesh under your character and add an additional force if its not equal to Vector3.up.
For stairs: increase character controller slope limit or remake your stair’s collide mesh.

If your not using character collider (you aren’t) then raycast down below the play to check if they are on ground, when you are not on ground implement your own gravity with addforce function (turn off gravity on the ridged body) when you do make contact with the ground then don’t applied that gravity. Finally tweak your raycast distance (the further the steaper angle stairs/slopes you can walk on also as the previous answer stated have the slope above the stairs), drag (I find 3 to be a good starting point), friction (I like none) and bounce (around 0.05 it helps with jumping up blocks, cause at 0 you get stuck on corners) finally don’t ask me how you can have drag when there is 0 friction.
Hope this helps.