First, you will want to take note if the cat is healthy. Additionally, look for a tipped-ear or a collar. If a cat has either of these and it appears healthy, this cat is being cared for and should be left alone.
Second, if the cat is not causing a nuisance* and it appears healthy, it is best to leave the cat alone, or if you think it needs spayed/neutered, rent a trap from the shelter and check out our spay/neuter resource pages.
Ultimately, if a cat seems safe and healthy, the best option is to get it spayed/neutered and return it to where you found it. The shelter should be the absolute last resort for any animal.
*if a cat is causing a nuisance, contact the shelter to discuss mitigation practices. The vast majority of the time, once a cat is spayed/neutered, nuisance behavior will stop.