Just yesterday I wondered why on earth the seven dogs I was walking could sit but not stay....I thought gee, I must be a bad dog trainer, then I remembered they are not my dogs and stopped worrying hehehe (to all my clients dogs featured: don't worry your dogs are awesome, this environment was simply too distracting for them)
On a serious note! Don't worry, your dog isn't being disobedient, most often the reason is that the dogs sit-stay training is incomplete.
There are 3 parts to sit-stays and owners tend to get 1 part or 2 of those parts right and miss the 3rd.
1. Duration: the first step of a sit-stay should involve you and your dog remaining still and start at only 1 second and slowly build up.
2. Distance: once your dog understands the concept of remaining still for 10 seconds, then you might think about taking a tiny step away from them, BUT you don't straight away expect they can hold still for 10 seconds, you would only step away for 1 second, then step back and reward them for this accomplishment. Now you slowly build the duration once again while only taking 1 step away. Then you can slowly increase the steps.
3. Distractions: once your dog understands that he must sit and stay in a quiet low distraction boring environment you can then add very small distractions or change the environment but you must once again lower the standards for distance and duration.
Sit-stays are not that hard to teach but you must follow the rules, stick to your dogs pace and make each step easily achievable.
Lastly if you want your dog to sit and stay in many locations you must practice in many locations, you can not simply expect them to go from a 10 second sit-stay in your back yard to a 10 second sit stay off leash on your walks.
Good luck and happy training!