URGENT: An List of a class problem

Good morning guys
I have a list of a class like:

[System.Serializable]
public class Person {
 public string Name;
 public string Surname;
 public int dateOfBirth;
}

public class NewScript1 : Monobehaviour {
 public Person[] People;

 ...
}

This is not the script, but a similar.
The problem comes when I make it code-generate I mean something like this:

public void GeneratePeople (int length) {
 People = new Person (length);
 for (int i = 0; i < People.Length; i ++) {
  GeneratePeople (i);
 }
}

public void GeneratePeople (int index) {
 Person per = new Person ();
 per.Name = Names[(int) Mathf.Round (Random.Range (0, Names.Length-1))];
 per.Surname = Surnames [(int) Mathf.Round (Random.Range (0, Surnames.Length-1))];
 per.dateOfBirth = (int) Mathf.Round (Random.Range (1900, 2000));
 People[index] = per;
}

I have tried using a loop, and it assign to the hole list the same value, then I have tried to do it manually. It assign to the hole list the last value.
Why? How can I fix this?
Please Help.
Thanks
New Dev

I have found the way:
You need a void like this in the class

public Person Copy () {
 Person a;
 a.Name = Name;
 a.Surname = Surname;
 a.dateOfBirth = dateOfBirth;
 return a;
}

and then instead of using like in the GeneratePeople (int index) at 13 line

 People[index] = per

use

 People[index] = per.copy ()

You need [ ] and not () to instanciate an array, could that be leading to your error ?

public void GeneratePeople (int length) {
 People = new Person[length]; // Try this
 for (int i = 0; i < People.Length; i ++) {
   GeneratePeople (i);
 }
}

Plus, your 2 methods have the same prototype, is that a typo ?

And instead of passing the index to the function, simply return the object you instanciated and assign it from the calling method, your code will be cleaner.

also RoundToInt will cause you to not need the cast
and if you use RandomRange on ints you don’t need to round, it is already an int.