Assuring an efficient Quality of Service (QoS) for heterogeneous Internet of Things services is a challenge, mainly due to spectrum scarcity and bandwidth limitations on the radio access network. To solve these problems, efficient management of airtime per station (STA) is necessary. In this work, we propose a scheduler to perform dynamic network slicing in IEEE 802.11ah Networks. The proposed scheduler is based on virtualization technologies to assure QoS restrictions per slice and can be deployed in the Access Point (AP) or in a virtual machine connected to the AP. Network metrics are used to verify QoS violations per slice over time. Once a QoS restriction is detected, the scheduler performs a reallocation of resources re-configuring the Restricted Access Windows parameters that compose a slice, adjusting airtime per STA. To evaluate the proposed scheduler, we consider a dynamic policy. Simulation results in a smart city scenario show that the dynamic policy is able to scale the network and satisfies QoS slice requirements.