You can create a SYNONYM for that object - as in:
CREATE SYNONYM dbo.MyTableName FOR [linked server].db.dbo.TableName;
Then, in your code you reference your synonym:
SELECT {columns} FROM dbo.MyTableName;
If the linked server changes, or the database is moved to the local instance, you just drop the synonym and recreate it with the new values.
Of course, if you want something that is dynamically defined by a parameter or something like that then you need use dynamic SQL.