Is "to do something" a preposition phrase?
Mary tries [to do her homework].
"Tries to do her homework" is a verb phrase functioning as the predicate of the sentence.
"Tries" is a catenative verb and the infinitival clause "to do her homework" is its catenative complement.
As Pax comments in their answer, "to" is not a preposition here but a subordinator, a special marker for VPs of infinitival clauses.
The term 'catenative' is derived from the Latin word for "chain", for the construction is repeatable in a way that forms a chain of verbs in which all except the last has a non-finite complement. In your example the chain is a short one consisting of just the two verbs "try" and "do".