Oracle Message ORA-01121 - cannot rename database file string - file is in use or recovery

ERRORcannot rename database file string - file is in use or recovery
CAUSEAttempted to use ALTER DATABASE RENAME to rename a datafile that is online in an open instance or is being recovered.
ACTIONClose database in all instances and end all recovery sessions.