In the US, the term “apartment” generally means any space where the people are renting and there are multiple units in one building, and usually multiple buildings as well. They can be one, two, or 20 stories tall. Most are 2 or 3 stories except in very urban areas.
The exact same building or buildings, but where the occupants own their individual spaces and a share of the common facilities would be called a “condominium.” Each unit is a “condominium,” or “condo”, and the whole thing is called a "condo complex " or a “development”.
So those terms refer to financial arrangements, not architecture.
A “house” is an arrangement where one building and the land under it are owned by one group of people who live together, typically a family, and there is no element of common ownership with any neighbors. Sometimes called a “single-family house”. These can also be rented, but they keep the term “house.” So “house” is both an architectural and a financial term, but predominantly architectural.
A somewhat obsolete term, “apartment house” refers to a 10-30 unit apartment building all in one building and generally 2 to 4 stories tall except in urban areas. These tend to be built like hotels, with central hallways and common entry/exit lobbies, rather than each ground floor unit or stack of untis having their own exterior door.
In addition to the common term “duplex” you sometimes here the terms “triplex” (pronounced TRY-plex) and “fourplex”. I’ve never heard the term “quadplex”. These terms describe architecture. Duplexes are sometimes rented as apartments and sometimes sold as condos.
The term “townhouse” in newer development (last 50 years) is sometimes used as a straight synonym for condo, but generally applies only to denser one-and-two story designs. So that term is part architecture & part financial.
“Row house” refers to units built with common walls between units or built very close together with at most a narrow walkway between. Generally these have no front yard, are in urban, or ersatz fake-urban settings and each unit has a small fenced rear yard. Some are condo, some are single-family houses.
Slightly less dense developments than row houses are called “patio homes” Architecturally, these are smallish houses on very small lots. The goal is minimal yard area to maintain yet still have no common walls and a small patch of green someplace. Some are condo, most are single-family separate-ownership. Very popular with the retirees.
The real estate goons are forever coming up with new terms and new meanings for old terms, but I think I’ve pretty well covered the terms I’ve seen used in the various parts of the US I’ve lived.