I agree with what these two have already posted.

In addition at her age it's possible that she has arthritis and is finding stepping over into the litterbox to be painful. There are some meds a vet can prescribe for her if it is arthritis that may help.

Be aware that the longer the problem goes on without treatment the more of a habit it becomes and is more difficult to reverse even if the original cause is treated.

Good luck, and keep us posted.