A rayquaza spawned in a sunflower plains biome, so I went to go catch it with a masterball and got a message in chat that read "You can't catch Pokemon you already own!". The masterball was used outside of battle by right clicking, and was also used while flying on a metagross. After the masterball hit the rayquaza, it returned to my inventory and produced the message mentioned earlier. The rayquaza did not go into my party or pc.
The message is at the bottom of the chat box and I had 12 master balls before and after attempting to catch the rayquaza.