Pelosi said ‘Congress must immediately pass legislation’ but did not suggest Democrats would be willing to shut down government