Classically there are, roughly speaking, four basic elements to Japanese-style RPGs:
While these four basic elements are in principle completely independent of each other (in the sense that you could take any of them out and still have playable game, even if slightly less interesting), in a good JRPG they are closely related and tied together. Pulling this off successfully to make an interesting game requires a lot of things to be done right.
The story has to be closely related to the world you are exploring, in other words, the story is immersed in the world presented by the game, and the world fully supports and represents the story. Most places in the world (such as towns, cities and other such places) can usually be easily remembered by the player because of what happened there or how they were related to the story.
A good story will expose the characters, their backstories and personalities, and make the user empathize with them. (It often happens that if there are more playable characters than can be used at one time, and the player is given the option to select the characters, there will be some characters which are the player's favorites, and not necessarily because of pure gameplay reasons, but because the player empathizes with them the most, or likes them because of storytelling reasons. The stronger this phenomenon is, it usually means the better the storytelling has succeeded in its goal.)
While world exploration is usually somewhat limited (in other words, the outworld of the game is not a completely open sandbox), a good JRPG will still give a lot of freedom of exploration. Moreover, part of advancing in the main plot will depend on exploration (in other words, searching and finding something, rather than everything being given to the player automatically). The degree of non-linearity will depend highly on the game, but in a good game there will be some degree of it (where eg. the order in which certain towns or cities are visited is not fixed). Optional sidequests will also add to the non-linearity of the game (at least if the order in which sidequests can be done is not fixed).
In good JRPGs locales, such as towns and cities, are more or less open sandboxes. While their complexity varies wildly from game to game, the general rule is that they don't force you to any given path, but feel more like real towns (even if somewhat unrealistically small ones).
In a good JRPG non-playable characters (eg. in towns) can help expose the story. Speaking to them is a staple of JRPGs, and if implemented properly, it can add to the richness of the game.
All the older JRPGs by both Square and Enix (who later merged into one single company) where like this. Perhaps the most acclaimed one is Final Fantasy VI (originally published with the name "Final Fantasy III" in the west, an unfortunate policy of that time which has caused a lot of confusion), which is considered by many to be one of the best console games ever made.
In the 2000's Square Enix has taken a different direction with their JRPG games, at least with some of them. A direction away from the classic JRPG pattern. A direction for the worse.
Dissidia: Final Fantasy is not a JRPG per se, but more like a combat system mini-game blown to full game status. It uses all the main characters from Final Fantasies 1 to 10 as playable characters. While this is not a JRPG per se, I think it's very representative of this new direction Square Enix is taking: There's a very weak storyline which is completely disconnected and detached from the scenery that the game presents and almost completely disconnected from the characters (there's almost no narrative character development). The scenery is completely abstract and represents nothing related to the story.
Crisis Core: Final Fantasy VII (a prequel to the original Final Fantasy VII) is one of the first actual JRPG examples which start showing this new direction Square Enix is taking. This game feels more like an action adventure game of the God of War genre than a JRPG. Levels are completely linear and there is no freedom of exploration, and the story is only loosely connected to the scenery. There are no towns with shops anymore (instead, you can shop from anywhere). In-between levels you can explore a city, but even that seems disconnected from everything else, and is quite limited. There are no sidequests per se, more like "side missions" which are little else than combat training with some loot awards.
Some people could perhaps argue that Crisis Core is not really a JRPG (and not even intended to be such), but a representative of a somewhat distinct game genre, with only some JRPG elements. The same cannot be argued from The Last Remnant.
The Last Remnant is clearly a more traditional JRPG (and intended to be such). However, this one also shows heavily this new direction that the company has taken: While the storyline is more connected to the game's world and to the characters, there is basically no overworld exploration at all, and exploration within cities is also heavily limited. While the gameplay is not completely linear, it's significantly more so than in more traditional JRPGs.
Final Fantasy XIII could be considered the epitome of this new direction. A game cannot possibly get more linear than this. Even most first-person shooters are less linear than this game. There is no exploration element to this game at all, not even the little much there was in The Last Remnant. The scenery is also highly abstract and detached from the story. There is no sense of the story happening and being related to the world presented by the game. The story is also really vague, confusing and hard to understand and remember. It's hard to empathize with the characters because their involvement in the story is so vague.
Even worse, the combat system has been greatly simplified compared to previous games. In fact, one gets the feeling that everything in this game has been greatly simplified: The world (no exploration whatsoever), the main quest (follow a narrow corridor), the shopping system (you don't need to go to towns and their shops, instead you can access shops from anywhere, ie. the same gimmick as in Crisis Core) and the combat system. The only thing that has not been simplified is the story which is, as said, confusing and hard to follow. (Well, it's not that it's hard to follow because of being a complicated story. It's hard to follow because it's outright boring. There's nothing interesting in the story.)
It seems like Square Enix is testing new ideas with these games. However, they are clearly going to the wrong direction with this. Simplifying the games to the point where they become outright boring to play is not the correct direction you want to take with games which should be as complex as role-playing games are.
Why are they following this deadend path? The games are boring to play, and there's very little left of the richness of the older games.
Square Enix has definitely lost the ball. What was once by far the number one producer of JRPGs (well, two producers because Square and Enix were independent comanies back then) has taken a path to the dark side, and their games are just mediocre.
Fortunately Square Enix is not the only producer of quality JRPGs. Good alternatives include companies like tri-Ace (their games are usually published by Square Enix, but they should not be confused as being developed by Square Enix), tri-Crescendo, Mistwalker and Namco Tales Studio.