'incrementing' the name means you must somehow know what the previous name you renamed to was.
perhaps it is easier to rename to the current timestamp, like 20011031211033 (YYYMMDDhhmmss)
That way you nearly always have a unique filename (unless you rename twice in one second) and the filename tells you something about when the file was renamed.