All three of these drinks start from the same place, one or two shots of espresso, and the entire difference between them comes down to how much milk gets added and in what form. Once you know the ratio, the names stop being confusing menu jargon and start being useful information.
A traditional espresso macchiato is barely a milk drink at all. "Macchiato" means "stained" or "marked" in Italian, and that is literally the drink, a shot of espresso with just a dollop of foamed milk on top, meant to soften the espresso's sharp edge without diluting its strength. It is worth noting that a lot of large chains have popularized a very different, much sweeter "caramel macchiato," which is closer to a flavored latte and bears little resemblance to the traditional Italian drink of the same name.
A cortado sits one step up in milk ratio. Originating in Spain, it is traditionally espresso cut with roughly an equal amount of steamed milk, with little to no foam on top, giving you a drink that is smoother than a macchiato but still noticeably more coffee-forward than a latte. It is served smaller than a latte or cappuccino, usually in a small glass, which is part of why it has become a favorite among people who want milk's texture without losing the espresso underneath it. Sprudge's explainer on the cortado pins the proportions down further if you want the precise version.
A flat white pushes further into milk territory while staying more concentrated than a latte. Popularized in Australia and New Zealand, it uses steamed milk with a very thin layer of microfoam, generally poured over a double shot, resulting in a drink that is creamy and smooth but still lets the espresso come through more clearly than a standard latte does, largely because the ratio of milk to coffee is smaller and the milk itself is textured more finely. Sprudge's flat white explainer goes into the Antipodean origin argument, which is livelier than you would expect.
Where a latte fits into all of this is worth spelling out for comparison, since it is the drink most people already know. A latte uses considerably more steamed milk than any of the three above, with just a thin cap of foam, producing the mildest, creamiest, most milk-forward drink of the bunch. If you find a flat white or cortado still tastes too strong, a latte is the natural next step up in milk.
None of these three is objectively "better" than the others, they are calibrated for different amounts of milk tolerance and different intensities of espresso flavor. If you genuinely love the taste of espresso and only want milk to round off the bitterness, order a macchiato. If you want smoothness without losing the coffee, order a cortado. If you want a genuinely creamy drink that still tastes distinctly like coffee rather than warm milk, order a flat white.
Menu naming is not perfectly standardized between shops, especially once a drink crosses into large commercial chains, so if you order one of these somewhere new and it does not match the ratio described here, that is a real, common inconsistency in how these names get used, not a mistake on your part. When in doubt, just describe the ratio you want, mostly espresso with a little milk, or genuinely milky, and let the barista match it to whatever they call it on their own menu.