you can resign anytime , company / employer is bound to release you. your gratuity or other benefits depends upon your Contract. As per Qatri Labour law , after 1 year you get 21 days leave with pay and Gratuity.