Recently we have provided a build and guideline document to our client and by mistake they have set up a library with the wrong internal name. In the beginning  it worked well but as the additional functionality was added, it broke. As the users have started working on that, we needed to fix the internal name anyway.
hostforlifebanner
Our library internal name is “TrainingDocuments” and display name is “Training Documents”. While Client has set up “Training Documents”

Solution

Initially we thought it might be not possible. But then we found 2 ways to do it,

Approach 1 – Using SharePoint Designer 2013

Follow the below steps to fix this using SharePoint Designer 2013,
  1. In SharePoint Designer, Open your site.
  2. Navigate to All Files navigation node (not List and Libraries node),

    Note
    you will need “Site Collection Administrator” permission in the site collection to see “All Files” option.

  3. Find your list there
  4. Right-click list
  5. Rename.

Approach 2 – Using PNP PowerShell

In case you are not able to connect the site in the SharePoint designer or you do not have it installed in your machine, you can do this using PNP PowerShell as well.
PowerShell to change Library Name,

PowerShell to change List Name

For list, we don’t need to execute command for root folder changes. So, the updated powershell is as follows: