There are no rules which dictate interactions between Time Stop and being Grappled
There is no provision in the Time Stop spell to clear the Grappled condition (or any other condition), and no provision in the Grappled condition that indicates Time Stop would clear it (unless the Grappler can be considered incapacitated). Since (when discussing RAW) spells only do what they say they do, this means that casting Time Stop does not clear the Grappled condition on the caster.
This means that the caster's movement speed is zero (per Grappled condition) until they use an action to escape.
Escaping a Grapple. A grappled creature can use its action to escape. To do so, it must succeed on a Strength (Athletics) or Dexterity (Acrobatics) check contested by [the grappler's] Strength (Athletics) check.
Since, again, there are no rules that say otherwise, the grappler would still be entitled to a Strength (Athletics) check to prevent the caster from escaping.
Escaping a grapple does not affect any creature besides the caster, however, so doing so would (at least) not end the Time Stop.
However, there is a negative interaction between Time Stop and being the one doing the grappling
Either moving or releasing a grappled creature do affect another creature (the grappled creature). If the caster had initiated a grapple (or counter-grappled to avoid being dragged around), taking either action would (under RAW) end the Time Stop; and the caster would have to either remain in place or end the spell early.
Both of these are based on legalistic interpretations of Rules as Written
As with anything in D&D, these are subject to DM's ruling.
At my table, I would probably give the caster Advantage on escaping grapples, and allow them to release creatures (but not drag them around) without ending the Time Stop.