You can buy a 'new' car warranty if you are still within the original factory warranty coverage. If you are out of the manufacturers 'new' car warranty, then you are buying a 'used' car warranty.
New car extended warranties begin with the original 'in-service date' and with odometer sitting on zero, regardless of when you buy it. If the warranty begins with the current date and mileage, then you are buying a used car extended warranty.
New car extended warranties cover a lot more than used car extended warranties.
Manufacturer extended warranties are almost always better than 3rd party warranties. Much better and you don't have to worry about the company going out of business.
The dealership is making money on selling the extended warranty, so try to haggle. Even call around before you buy and talk to different finance (business) managers about what they'd charge if you came in and bought the warranty from them. You may get a better price. If the car is eligible for a new car extended warranty then another BMW can sell you the warranty, but you won't be able to finance it with the car loan.
If it's not eligible for a new car warranty he won't be able to sell the extended warranty, at least not without an inspection which someone will have to pay for (you).
Again, third party extended warranties are often a disappointment, esp for a car like the BMW where costs of repair are particularly high.
Lastly but not least, if you buy from a corporate chain dealership make certain you are talking about a manufacturers warranty not a third party warranty. Corporate stores usually sell their own or 3rd party warranties for additional profit.