If concentration of K+ ions inside the cell is almost equal to concentration of Na+ ions outside of the cell why these ions cross the membrane?
In order to understand why this happens, you have to recall the permeability characteristics of the plasma membrane. It seems that the movement of ions to and fro the cystol is counterproductive however this is not so. Actually there is unequal distribution of ions in the extracellular fluid and cytosol


  Extracellular fluid is rich in Na+ and chloride ions (Cl–). In
  cytosol, however, the main cation is K+, and the two dominant anions
  are phosphates attached to molecules, such as the three phosphates in
  ATP, and amino acids in proteins.


Differences in intracellular and extracellular concentrations of ions result primarily from:


the Na +/K + pump and 
the permeability characteristics of the plasma membrane.


Ions pass through the plasma membrane through ion channels. The two major types of ion channels are leak channels and gated ion channels.

i. Leak Channels

Leak channels, or non-gated ion channels, are always open and are responsible for the permeability of the plasma membrane to ions when the plasma membrane is unstimulated, or at rest. The plasma membrane is more permeable to K +and Cl- and much less permeable to Na+ because there are many more K + and Cl- leak channels than Na+ leak channels in the plasma membrane.
Because the plasma membrane typically has more K+ leak channels than Na+ leak channels, the number of potassium ions that diffuse down their concentration gradient out of the cell into the ECF extracellular fluid ECF is greater than the number of sodium ions that diffuse down their concentration gradient from the ECF into the cell. See below



The plasma membrane is relatively permeable to K + and much less permeable to Na + and to negatively charged molecules found inside of the cell. Consequently, positively charged K + tend to diffuse out of the cell through K + leak channels, leaving the negatively charged molecules behind, thus polarizing the membrane. The membrane is at equilibrium when the tendency for K + to diffuse out of the cell is resisted by the negative charge of the molecules inside the cell.

ii. Gated Ion Channels

These channels open and close in response to small voltage changes across the plasma membrane. The movement of ions into or out of the cell changes the charge difference across the plasma. membrane, which causes voltage-gated ion channels to open or close. Voltage-gated channels specific for Na+ and K + are most numerous in electrically excitable tissues

The Na+/K+ Pump

The differences in K + and Na + concentrations across the plasma membrane are maintained primarily by the action of the Na + –K + pump. Through active transport, the Na+/K + pump moves K+ and Na+ through the plasma membrane against their concentration gradients. Potassium ions are transported into the cell, increasing the concentration of K + inside the cell, and Na + are transported out of the cell, increasing the concentration of Na + outside the cell. Approximately three Na+ are transported out of the cell and two K + are transported into the cell for each ATP molecule used. These pumps help maintain the resting membrane potential by pumping out Na+ as fast as it leaks in. At the same time, the Na+/K+ ATPases bring in K+.

In summary it is important to note, there is uneven distribution of ions in and outside the cytosol.
Because the plasma membrane has more K+ leak channels than Na+ leak channels, the number of K+ ions that leave the cell is greater than the number of Na+ ions that enter the cell. As more and more K+ ions leave the cell, the inside of the membrane becomes increasingly negative and the outside of the membrane becomes increasingly positive. The inability of most anions to leave the cell also contributes to the negativity of the resting membrane potential. These trapped anions cannot follow K+ out of the cell because they are attached to non-diffusible molecules such as ATP and large proteins.

Nevertheless, sodium ions do slowly diffuse inward, down their concentration gradient. If not controlled, such inward leakage of Na+ would eventually destroy the resting membrane potential. The small inward Na+ leak and outward K+ leak are offset by the Na+/K+ ATPases (sodium pump)

This diffusion accross the plasma membrane is necessary because:


There is uneven distribution of ions which needs to be corrected.
The characteristics of the plasma membrane has lot to do with how transport of substances occur ( It is important to note that not only ions use this path, other substances vital for cell growth have to use this path as well, therefore strict control is necessary) 


Hope this helps

References


Anatomy and Physiology (Seely)
Principles of Anatomy and Physiology (G. Tortora, B. Derrickson)