How to make XBee sleep?
First of all you have to configure your XBee with atsm = 5 and atdi7 = 0. then is better to use one 10k resistor between pin 6 and dtr/sleep_rq and finally when you want the XBee to sleep do not let the program to print the numbers from 5-10.

This is your code updated:

#include &lt;avr/sleep.h&gt;
#define XBEE_sleepPin 6

void setup() {
  Serial.begin(9600);
}

void xbeesleep() {
  Serial.println("sleep");   
 delay (3000); 
  pinMode (XBEE_sleepPin,OUTPUT);    // put XBee to sleep0
  digitalWrite(XBEE_sleepPin,HIGH);  // Setting this pin to LOW turns off the pull up resistor, thus saving precious current
}

void xbeewake() {
  Serial.println("wake");    
  pinMode(XBEE_sleepPin,OUTPUT);   // Set the "wake-up pin" to output
  digitalWrite(XBEE_sleepPin,LOW); // wake-up XBee
  delay(1000); //make sure that XBee is ready
}

int i = 0;
void loop() {
  if (i==0)
    {
     xbeewake();
    }
  else if (i==5)
    {
    xbeesleep();
    }
  if (i&lt;5)
  {
  Serial.println(i);
  }
  i = (i+1) % 10;
  delay(3000);
}