Yes flashlights are allowed on airplanes in both your checked luggage and your carry on luggage.
However if the flashlight is too large then it must be brought on the plane in your checked baggage.
If the flashlight is smaller then the flashlight can be brought on the plane in your carry on luggage.
According to the TSA and airline regulations the flashlight can be brought on the plane in your carry on luggage as long as the flashlight is less than 7 inches when measured from end to end they are allowed in your carry on.
If the flashlight measures larger than 7 inches when measured from end to end then the flashlight can still be brought onto the airplane but it must be placed in your checked baggage.
Some larger flashlights can be used as a weapon so that's why the larger flashlights must be put in the checked baggage.
Smaller flashlights can be brought on the plane in your carry on luggage.