A pilot has been indicted for allegedly threatening to shoot the captain if the flight was diverted