In summary, the data may be in various locations, where it is may change automatically (by actions of the operating system), and, when working within normal programs, you generally do not need to know about it.
First, the fact that you declare an array in source code does not necessarily mean the full array, or any array at all, is created in memory. A compiler may optimize the source code in ways that eliminate part or all of the array.
However, let us suppose the array is actual created. Virtual memory is created to present an illusion that a process has exclusive use of physical memory and/or that it has more memory than is actually available as physical memory. A purpose of this illusion is that processes should not have to be concerned about where their data actually is. And the vast majority of normal processes can neglect that.
Also, for the most part, compilers will pay little attention to where small objects are placed relative to page boundaries. It usually will make little difference whether an array of 100 int is placed so that it is entirely within one page or that it spans a page boundary.
When it is necessary to know or influence where the data actually is, a number of issues come into play.
There are ways to affect the location of data relative to page boundaries, either by using system or library calls for that purpose or by allocating excess memory and then putting the data at a chosen location within it.
If data is important and is preferred or required to remain in physical memory, there may be system calls (depending on the system, of course) to request that.
In the absence of such specific requests, where data is located depends on a number of factors. If you declare a static array of int and initialize it with compile-time data, the data may appear in a section of the executable file that is ultimately generated. In some systems, when an executable file is started, the system does not load the entire file into memory. It loads various portions of data from the executable file only when they are referenced. Thus, this data may initially reside on disk. After it is loaded into memory, if the system is burdened with other things that need memory, the system may discard this data from memory, so that it again exists only in the executable file on disk.
On the other hand, if the data is generated during program execution, it is of course in memory when the program generates it. Again, though, if the system is burdened with other demands, the system may remove the data from memory. In this case, since the data does not already exist on disk (as the data in the executable file did), the data is first written to a page or swap file on disk.
Generally, where the data is may change over time.