added addPerson method implementation