Why does Yubaba offer a job to Chihiro, rather than just turning her into piglet? From the beginning of the film, it looks that Yubaba is searching for Chihiro with the clear intention to turn her into animal. 

What reasons prevent Yubaba to do so when Chihiro suddenly comes to her office? While being rude, Yubaba still talks to Chihiro and at the end offers to sign the job contract. Looks like Yubaba is restricted by some rules she must follow. Why, and what are these rules?
She cannot refuse her as long as chihiro asks. Yubaba also has a rule not to turn down anyone asking for a job and therefore has to give her the job and can't be turned into a piglet as she is under her service.