The pricematch can vary, i got them to pricematch a phone at walmart but it was a corporate store and i spoke with the manager.
Yes you can return the phone (you have 30days) which will put you back in your original status of being eligible for an upgrade. As for the unltd data you can keep it. hopefully the people at costco know what thy are doing and dont mess up, there have been reports of people losing their unltd data but a few calls back to ATT should get that resolved if that is the case here. if they do remove it at costco once you call att back they can look at your past billing to see that you did have the unltd data plan and therefore you should still have it.
but maybe when you go to return the phone to ATT and they ask why and you mention getting it cheaper at costco they may just do the pricematch then. looks better for the store to have a sale (even for less money) than it does for a return