How do multiple accounts on Play Store work? I have 2 accounts on the device:

abc@gmail.com - Main Account

xyz@gmail.com




With account abc@gmail.com selected on the Play Store, I've downloaded app XPTO and bought some stuff via In App Billing. 
I then uninstall it
Change to account xyz@gmail.com on the Play Store 
Downloaded the app with that account.


What I'm seeing is that all bought items by account abc@gmail.com are present, although I've downloaded with the account xyz@gmail.com, is this a normal behaviour? 

Besides that whenever I try to buy a new product via In App Billing, the Play Store popup to buy it, shows the account abc@gmail.com and not xyz@gmail.com

Can someone explain this behaviour?



Update: 

I've found another thread about this: Change Gmail account to make in-app purchase?
To answer the first part of your question, your list of purchased apps in the Play Store is a union of all of the purchased apps on all of your Google accounts. As long as your abc@gmail.com account is logged in on your phone you will have access to all apps purchased on that account. This does NOT mean that they in any way become affiliated with any other account, as removing the purchasing account from your device will disable any paid app that checks for a license and it will no longer show up as PURCHASED in the Play Store. Migrating paid apps from one account to another is a task that Google has left up to app developers to handle and you have to appeal to them to grant your other account access.

So in summary, the list of purchased apps in Google Play is completely independent of which account you have currently selected within the Play Store.

As far as changing your main account, the only way to do this is to perform a Factory Reset and sign in initially with your other account. The main account is so tightly ingrained in Google services that it cannot be changed without wiping your phone. And this process affects a lot more than just In-App purchases.