Why wasnt Palestine given a state when Israel was ?

Simply because Israel as an occupier of Palestinian lands is against giving Palestinians a state and doesn’t recognize the right of Palestinian self-determination. Israel wants maximum Palestinian lands, and minimum Palestinians. This is the unfortunate reality.