Input.GetKeyDown is not working C#

Hello, I spent the whole afternoon working on this script and more than three hours trying to see because it does not work and tried various methods but still does not work , as far as I get to see the code not contradicted . The problem is this, when I use Input.GetKeyDown functions to be mounted in the car but when I pressed again not take me out of the car. All code works fine if I do it from the inspector but when I try to do from the keyboard as is supposed to be will not let me leave.

code:

    using UnityEngine;
    using System.Collections;
    using UnityStandardAssets.Vehicles.Car;
    using UnityStandardAssets.Characters.ThirdPerson;
    using System.Collections.Generic;
    
    public class MontarseEnElAuto : MonoBehaviour {
    	//Transforms
    	public Transform player;
    
    	public Transform montadoTransform;
    
    	public Transform fueraTransform;
    
    	public Transform carroTransform;
    
    	//Logica
    	private int salio = 0;
    
    	private bool montado = false;
    
    	private bool puedeSalir = false;
    
    	//Gameobjects
    	private GameObject carro;
    
    	private GameObject playerGO;
    
    	void Start()
    	{
    		carro = GameObject.FindGameObjectWithTag("Player");
    		playerGO = GameObject.FindGameObjectWithTag("Jugador");
    	}
    	void Update()
    	{
    		//Montado
    			if(montado == true)
    			{
    				player.transform.position = montadoTransform.transform.position;
    				carro.GetComponent<CarUserControl>().enabled = true;
    				playerGO.GetComponent<ThirdPersonUserControl>().enabled = false;
    				playerGO.GetComponent<ThirdPersonCharacter>().enabled = false;
    				playerGO.GetComponent<CapsuleCollider>().enabled = false;
    				playerGO.GetComponent<Rigidbody>().useGravity = false;
    				playerGO.GetComponent<Rigidbody>().isKinematic = true;
    				playerGO.GetComponent<Animator>().enabled = false;
    				salio = 1;
    			}
    		//Demontado
    			if(montado == false)
    			{
    				carro.GetComponent<CarUserControl>().enabled = false;
    				playerGO.GetComponent<ThirdPersonUserControl>().enabled = true;
    				playerGO.GetComponent<ThirdPersonCharacter>().enabled = true;
    				playerGO.GetComponent<CapsuleCollider>().enabled = true;
    				playerGO.GetComponent<Rigidbody>().useGravity = true;
    				playerGO.GetComponent<Rigidbody>().isKinematic = false;
    				playerGO.GetComponent<Animator>().enabled = true;
    				salio = 0;
    			}
    
    		if (puedeSalir == true && salio == 1)
    		{
    			player.transform.position = fueraTransform.transform.position;
    			puedeSalir = false;
    			salio = 0;
    		}
    	}
    	void OnTriggerStay(Collider other)
    	{
    		if(other.tag == "Jugador" && Input.GetKeyDown(KeyCode.F) && montado == false)
    		{
    			Debug.Log(montado);
    			montado = true;
    			Debug.Log(montado);
    		}
    		else
    			if(other.tag == "Jugador" && Input.GetKeyDown(KeyCode.F) && montado == true)
    			{
    				Debug.Log(montado);
    				montado = false;
    				Debug.Log(montado);
    			}	
    	}
    }

When you get in the car, you disable the collider and therefore OnTriggerStay will not be called any more.

Besides, the code to enter / exit will get called every time in Update().

Try something like this (untested):

void Update()
 {
      if (puedeSalir == true && salio == 1)
     {
         player.transform.position = fueraTransform.transform.position;
         puedeSalir = false;
         salio = 0;
     }
     
     if( montado == true && Input.GetKeyDown(KeyCode.F) )
     {
         Debug.Log(montado);
         ExitCar();
         montado = false;
         Debug.Log(montado);
     }                 
 }
 
 void OnTriggerStay(Collider other)
 {
     if(other.tag == "Jugador" && Input.GetKeyDown(KeyCode.F) && montado == false)
     {
         Debug.Log(montado);
         EnterCar();
         montado = true;
         Debug.Log(montado);
     }

 }
 
 void EnterCar()
 {
   carro.GetComponent<CarUserControl>().enabled = true;
   playerGO.GetComponent<ThirdPersonUserControl>().enabled = false;
   playerGO.GetComponent<ThirdPersonCharacter>().enabled = false;
   playerGO.GetComponent<CapsuleCollider>().enabled = false;
   playerGO.GetComponent<Rigidbody>().useGravity = false;
   playerGO.GetComponent<Rigidbody>().isKinematic = true;
   playerGO.GetComponent<Animator>().enabled = false;
   salio = 1;         
 }
 
 void ExitCar()
 {
   carro.GetComponent<CarUserControl>().enabled = false;
   playerGO.GetComponent<ThirdPersonUserControl>().enabled = true;
   playerGO.GetComponent<ThirdPersonCharacter>().enabled = true;
   playerGO.GetComponent<CapsuleCollider>().enabled = true;
   playerGO.GetComponent<Rigidbody>().useGravity = true;
   playerGO.GetComponent<Rigidbody>().isKinematic = false;
   playerGO.GetComponent<Animator>().enabled = true;
   salio = 0;   
 }