That’s because Mesh.triangles is a one-dimensional array, so is not valid.
Mesh.triangles is an array of vertex indices. You need to read 3 at the time to make up one triangle. The simplest example would be a quad. Let’s say you have a square, with these corners (doing it in 2D for simplicity)
You could define two triangles, the first one using vertices [0, 1, 2] and the second one with vertices [0, 2, 3]
With that in mind, Mesh.vertices would be an array of 4 vertices (the ones listed above) and Mesh.triangles an array of 6 indices: [0, 1, 2, 0, 2, 3], each group of 3 defining one triangle