Can an Air Genasi shoot a bow while using their racial levitate? How do the components of this spell work? A bow is a two handed weapon. I'm having a hard time figuring out my options for this Air Genasi Ranger I'm trying to build.
Material, somatic, and verbal components are only required during the casting of spells, not during the duration. Your character can't shoot a bow while casting a spell with material or somatic components, but once the casting is done, your character's hands are free to do whatever you want while the spell is ongoing.
Levitating does not change your attack options.
(See addendum at the end of this answer, which addresses the edit to the querent's original question.)
The levitate spell does only what it says.
One creature or object of your choice [you yourself are a valid choice] that you can see within range rises vertically, up to 20 feet, and remains suspended there for the duration.
It's a concentration spell, so losing concentration by casting another concentration spell or taking damage and failing the saving throw to retain concentration would cause you to fall, and...
When the spell ends, the target floats gently to the ground if it is still aloft.
So you would gently descend. Other than that, the normal combat rules apply. You can still use a melee or ranged weapon in the air as long as whatever target you are trying to attack is within range. You might find it hard to stay within range of a target due to the movement limitations of the spell, but it would not affect your attacks.
In addition, this applies whether you have the levitate spell because you are an air Genasi or because you have it from some other feature, such as being a wizard. The levitate spell works the same in any case.
Addendum: regarding spell components and free hands.
You added a stipulation to the question: do the spell's material and somatic components impact your ability to use a weapon? No.
Spell components are only used when casting a spell, not when maintaining concentration on a spell (unless specified otherwise). So once you have cast the levitate spell your hands are free to use your weapons as normal, even two-handed weapons.
Do note that the air Genasi's racial feature allows them to cast levitate without using material components, so you only need verbal and somatic components anyway.
You can make ranged attacks while levitating.
PHB 203, emphasis added:
A spell’s components are the physical requirements you must meet in order to cast it.
Levitate's casting time is only 1 action. This means that you only need to supply the necessary components during that 1 action, not during the entire duration of the spell.
The rest of the spell's 10 minute duration is covered by concentration: during this time, you have to keep concentrating on the spell in order to keep it active. PHB 203 states,
Normal activity, such as moving and attacking, doesn’t interfere with concentration.
Thus, you can concentrate on Levitate and make ranged attacks at the same time.