What you wan’t to do is considered a derivative work.
WordPress is under the GNU General Public License 2.(GPLv2). Under the GPL, if you make a derivative work of WordPress and distribute it to someone else, you must provide that person with the source code under the terms of the GPL so that they may modify and redistribute it under the terms of the GPL as well. Which in the case of a web application which provides the source already but if you redistribute it, it must inherit the GPLv2 or later allowing them to do the same with your whitelabel.
That isn’t to say that you are obligated to redistribute it to others than a single client, and if you are only using it internally you don’t need to redistribute it at all.
So you are free to modify it to your hearts content, as long as it stays GPLv2+ and you are freely allowing anyone that gets a copy of it to modify your own work under the GPL Version 2 or later(This does not include website visitors, you are not obligated to provide them access to the code).
For more information: GNU General Public License 2.0