Yes, an aircraft can stay in the air without going forward if the oncoming wind, called headwinds are equal or greater than th minimum speed of that aircraft. This principle is used in the wind tunnels to experiment the flight characteristics by blowing the wind to the aerofoil and assess the aerodynamic changes.