For example, is it possible to drink a flying potion and cast greater invisibility spell on myself (both spells would require concentration), so I can fly around invisible?
A Potion of Flying specifically doesn't require concentration.
In page 141 of the DMG under "Spells", it specifically mentions potions as an exception to the rule of concentration:
... Many items, such as potions, bypass the casting of a spell and confer the spell's effects, with their usual duration.
So, if the potion does not say it requires concentration, it's safe to assume that it doesn't. The potions listed in the DMG all say in parenthesis that they do not require concentration but your DM may invent a house-ruled potion that does require concentration, so it's still safer to ask your DM.
If a potion explicitly duplicates the effect of a spell that requires concentration, the concentration requirement remains.
Unless the potion's description states otherwise
Sage Advice Ruling
This is made clear in the Sage Advice Compendium (v. 2.6), which states that:
A potion’s effect requires concentration only if its description says so or if it duplicates a spell that requires concentration.
(p.5, emphasis mine)
A point of technical clarification: To 'duplicate a spell' here must be understood as shorthand for (explicitly) duplicating the effect of a spell. We may treat these as interchangeable because there is no precedent (at least, not in the DMG) for a potion which explicitly duplicates a spell; only the effects thereof are duplicated.
The many exceptions prove the rule
'Specific beats general' in the D&D rules (Basic Rules, p. 5).
In this paradigm, the inclusion of (concentration not required) in a potion's description implies that concentration would otherwise be required. The specific rule is consistently required as an exception to the general rule. This confers with the Sage Advice rules above.
The DMG does not list potions as an exception to concentration rules
As daze413 has pointed out, the DMG states that:
Many items, such as potions, bypass the casting of a spell and confer the spell's effects, with their usual duration.
This has no bearing on concentration, because concentration is part of a spell's duration and the need for concentration is consummate with the duration of the spell. This can be seen in the description of any spell that requires concentration. Casting does not take place, but concentration is still required.