Every Muslim country had educational centers before those modern universities emerged they were just not any match for what was present in Russia or Europe at the same time. The Muslim/Non Western world back then was a poor and illiterate backwater and Azerbaijan was not any different in the wider picture.
Yes, independence from Russia for a short while. 2 years if I am not wrong. Not an expert on Azerbaijani history.
Azerbaijan Democratic Republic - Wikipedia, the free encyclopedia
Which itself was a Russian client state if I am not wrong.
Still in 1920 Azerbaijan cheesed to exist and became a part of USSR. Claiming that Azerbaijan did not benefit from USSR in terms of education, school system and science is complete bogus that nobody can accept.