Why do airlines outsource regional flying?
This article breaks it down super nicely, and has most of the info you are looking for. The key quote from my reading of it is 


  The simple answer is that using regional airlines saves major airlines
  money compared to them operating a flight themselves. Where do the
  cost savings come from? For one, employees are paid significantly
  less.


There are also some serious union and historical reasons for the setup, regional airlines code sharing with majors is in some regards a way to skirt around union negotiations 


  The first reason is that it would likely eliminate the cost advantage.
  Most major carriers have negotiated with their unions that flights
  with fewer than “X” number of seats will be operated by regional
  airlines. You can bet that if the regional airlines became part of the
  major airline (even if a separate division), the major carriers’
  unions would be fighting for significantly better pay for those crews.
  
  ...
  
  Historically another reason the major carriers have contracted out to
  regional carriers is because it allows them to share some risk. Keep
  in mind that historically airlines are ridiculously unprofitable
  (though that has changed recently). So leased planes were almost a
  liability rather than an asset, given that they were losing money with
  just about each flight.


Here is another interesting paper on the subject and good info here.