If a buy a mac from another retailer, do I get the same warranty that I would get from Apple?
You'll get the same warranty from an authorized Apple retailer as you would from Apple directly. I don't know how prevalent it is today, but for a while you could buy refurbished Macs from non-authorized retailers and you ended up with little or no warranty. (Note that Apple sometimes sells refurbished machines that do have full warranties; the warranty's existence is dependent upon the authorization status of the retailer.)

Apple provides a way to determine which retailers are authorized on the Solution Professionals portion of their website. Be sure to check that list before making a purchase.