How to rename a file even when it shows permission Denied in Unix

While executing a script, I am not being able to able to create a file as the file with the same name already exists. That existing file is not getting overwritten as I am not the owner of the file. So, Neither am I able to rename the file nor delete the existing file, so as to get my file created.

How to rename the existing file and create my file from the script...

Are you talking of a temporary file? Not being the owner is that case may be secondary: The permissions on the directory containing the file are more relevant... Temporary files are found normally in /tmp or /var/tmp etc... and are set read/write to all, but in some cases it can hold a sticky bit that is for only owner of the file can remove it...

Can you modify the script?

If this is not a case of a single file then I would suggest to create your own directory and place all the files in it.

Otherwise you can check if file exists then create your file with some extension.
E.g.

fileName="name.txt"

if [ -e "$fileName" ] ; then
   file="name_new.txt"   # then create file
else
   touch $fileName    # create file with original name
fi