Using splice function,
var arr = [{id:1,name:"rajvir"},{id:3,name:"raj"}];
var obj = {id:5,name:"dhvani"}
arr.splice(2, 0, obj); //(index,how many?,Object)
console.log(arr);
//Output arr = [{id:1,name:"rajvir"},{id:3,name:"raj"},{id:5,name:"dhvani"}];