You can use
Oracle Express Edition. While it is not open source, it can be freely used even for business, but it has some limitations. It would be useful if you want to learn Oracle or want to develop software for Oracle specifically.
If you're using any other edition without a proper licence, you may be violating a law. There might be some provisions to use Oracle for learning purposes, but I'm not very sure about it. XE can be definitely used for free by anyone.