It's to do with codeshare flights and both BA and AY being in Amadeus. When a codeshare flight is booked, two PNRs are created; the marketing PNR (where the ticket is issued, and the flight is marketed as BAxxxx), and the operating PNR (where the operating airline holds the reservation on AYxxx).
Don't worry about it, that's just how it works.