Hi Kirandeep Kaur,
Make a list of that particular object in Controller class and initialize the object in any method and bind that method in Button in Visualforce page , Also take Boolean Variable and set ‘True’ the variable in method
For Example see the below code.
public list<contact> listOfContact{get;set;}
contact ContactObject= new Contact();
public void AddMoreContact()
{
accountBoolvalue = false;
contactBoolValue = true;
contact ContactObject= new Contact();
ContactObject.accountId= account.Id;
listOfContact.add(ContactObject);
InsertSuccess= false;
}