BGP is an Exterior Gateway protocol that is basically used to send routing information between different AS(autonomous systems). It uses TCP (transport layer protocol) to establish connection b/w the router that are sharing routing information , so we can say reliability is the motive behind TCP help..
So here question is about , to which layer it belongs ?
First we must have to know that OSI is just a logical model, if you sit and try to make punctilious work list like which layer do which work , then you can't i suppose because during network communication things are happening in quite a coalescence manner , like for example , what's the need of session layer ? does every network communication first establish session ? which layer specifically take care about data synchronization ? so what do i want to say is OSI is just a logical way to tell how communication is working b/w any two nodes..so when even we can't exactly distinguish b/w specific work of each layer , how can we distinguish about layer protocols ?
For me BGP , RIP are network layer protocols , but some consider those both protocols as kind of application which router uses...so they just count them in application layer...but what is application layer ? for me it's a layer user is directly connected to...yes! through some application like through browser you are directly using the services of HTTPS so it's no doubt application layer protocol... does here you are directly using RIP/BGP through some application ? NO then how can it be application layer protocol...
so don't fall in trap to taking care about which protocol belongs to which OSI layer...ARP belongs to which layer , that's also dilemma...some say network layer , some Data link..