EDIT: As pointed out by others, this is not legal, as it results in undefined behaviour. I've removed this sentence from my answer.
This has the potential to result in undefined behaviour. You've allocated a memory chunk of 10 ints long in the struct abc, so indexing into the 5th (6th) item will take you to y[0] as you've noted in THIS specific case.
Where you can run into problems is when the C compiler packs the structure in a way that you do not expect. This is called data packing or bit alignment. When the computer wants to access memory from your data structure, it will attempt to do so in uniform chunks for the entire structure. Let's use an example:
struct abc {
int a;
char b;
int c;
};
What do you expect the size of this struct to be? An int is 32 bits, and a char is 8 bits, so the total size should be 32 + 8 + 32 = 72 bits. However, you will find that on many systems, this structure is actually 96 bits in size. The reason is that char b gets bit packed on the end with an additional 24 bits to maintain a standard offset between variables.
This can be extremely confusing when you declare a structure in two different places, and one gets bit packed while the other does not due to compile time options or configuration.
Look up bit packing and data alignment or bit alignment for more information.