How to rotate entire scene instead of all objects in scene (P3D)

I have some code to make a scene and then I want to rotate the entire scene (not all the objects in the scene)
When I run this code it rotates the cube and the skysphere seperately, but I want the entire scene to rotate, not individually rotate both the skysphere and the cube

PVector pos;
PShape sky;
float x;
float y;
float xm;
float ym;
float speed = 0.01;

void settings() {
  size(800, 600, P3D);
}
void setup() {
  noStroke();
  sky = createShape(SPHERE, 2000);
  sky.setTexture(loadImage("data/img/back.png"));
}
void draw() {
  translate(width/2, height/2);
  stroke(0);
  x += xm;
  y += ym;
  if(x > 1.5) {
    x = 1.5;
  }
  if(x < -1.5) {
    x = -1.5;
  }
  println(x, y);
  rotateX(x);
  rotateY(y);
  shape(sky);
  pushMatrix();
  translate(0, height/2, 0);
  box(2000, 0, 2000);
  popMatrix();
}
void keyPressed() {
  if(key == 'w') {
    xm = 0.01;
  }
  if(key == 'a') {
    ym = -0.01;
  }
  if(key == 's') {
    xm = -0.01;
  }
  if(key == 'd') {
    ym = 0.01;
  }
}
void keyReleased() {
  if(key == 'w') {
    xm = -0;
  }
  if(key == 'a') {
    ym = -0;
  }
  if(key == 's') {
    xm = 0;
  }
  if(key == 'd') {
    ym = 0;
  }
}

if you need the background sphere to move ( rotate ) on key operation
but the object ( box ) not:
you need the push pop over the rotating sphere and not the box??

if you need them all to rotate: disable all push pop,
that looks correct to me

//PVector pos;
PShape sky;
float x,y,xm,ym;
float limit = 1.5,speed = 0.01;

void settings() {
  size(800, 600, P3D);
}
void setup() {
//  noStroke();
  sky = createShape(SPHERE, 2000);
//  sky.setTexture(loadImage("data/img/back.png"));
}
void draw() {
  translate(width/2, height/2);
//  push();               // add
  move();
  shape(sky);
//  pop();                // add
//  pushMatrix();
  translate(0, height/2, 0);
  stroke(200,0,0);
  fill(0,0,200);
  box(200, 20, 200);
//  popMatrix();
}

void move() {
  x += xm;
  y += ym;
  if (x > limit)  x = limit;
  if (x < -limit) x = -limit;
  println("x "+nf(x, 1, 2)+" y "+nf(y, 1, 2));
  rotateX(x);
  rotateY(y);
}

void keyPressed() {
  if (key == 'w')    xm = speed;
  if (key == 'a')    ym = -speed;
  if (key == 's')    xm = -speed;
  if (key == 'd')    ym = speed;
}

void keyReleased() {
  if (key == 'w'||key == 'a'||key == 's'||key == 'd')    xm= ym = 0;
}

but possibly you expect the box at a different position??

translate(width/2, height/2);
translate(0, height/2, 0);

should do what?
try disable the second translate and look again??