Occasionally, you might enter a configuration setting incorrectly or change your mind about the kind of network you require. If you installed WordPress, enabled the network, and then want to move it to a new location, you will encounter errors when changing the URL. The proper method is to move WordPress first, disable the network if you installed it, and then enable the network at the new location.
To change from subdomains to subfolders or vice versa, follow these steps:
To switch from subdomains to subdirectories, change false to true.
This saves and resets your permalink structure settings and flushes the internal rewrite rules, which are slightly different in subdomains than they are in subdirectories.
This process can't be done if you want to keep extra sites.