This is generally up to your supervisors. I imagine it totally varies, some are in every day 9-5 and others only pop in. You will benefit from being around peers though, rather than trying to work in isolation.
If you are doing a fulltime PhD, I wouldn't consider working, because it's really difficult to sustain both. If you're funded, you might find a stipulation with how many hours you can work e.g. only 6 hours per week during work hours on non-research focused work in the department.